Fixing test and refactoring a validation form.