more tests refactor