Writing test for user registration