Refactored registration tests