fixed test.
refactored test