refactoring ui tests