passed 10 tests with 58 assertions that works for all scenarios