From 69fa60080caaa9105691d0f67aa73addf5719913 Mon Sep 17 00:00:00 2001 From: Steve Howell Date: Mon, 3 Oct 2016 16:15:24 -0700 Subject: [PATCH] tests: Test get_prereg_user_by_email(). --- zerver/tests/test_signup.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/zerver/tests/test_signup.py b/zerver/tests/test_signup.py index 0162f33dab..85ed92eb0b 100644 --- a/zerver/tests/test_signup.py +++ b/zerver/tests/test_signup.py @@ -8,7 +8,7 @@ from zilencer.models import Deployment from zerver.views import get_invitee_emails_set, do_change_password from zerver.models import ( - get_realm, get_user_profile_by_email, + get_realm, get_prereg_user_by_email, get_user_profile_by_email, PreregistrationUser, Realm, Recipient, ScheduledJob, UserProfile, UserMessage, ) @@ -500,6 +500,9 @@ so we didn't send them an invitation. We did send invitations to everyone else!" # We only sent emails to the new users. self.check_sent_emails(new) + prereg_user = get_prereg_user_by_email('foo-test@zulip.com') + self.assertEqual(prereg_user.email, 'foo-test@zulip.com') + def test_invite_outside_domain_in_closed_realm(self): # type: () -> None """