refactored test to include more asserts