refactoring form test