refactored latest attempt test