fixing tests
fixing code