Add tests for registration.