Refactoring tests

unsuccessfully