tests: Include deactivated users for subscribe test.

This commit is contained in:
Steve Howell 2020-10-14 10:55:22 +00:00 committed by Tim Abbott
parent 2a4a775e2b
commit 193ca397f9

View File

@ -3280,6 +3280,12 @@ class SubscriptionAPITest(ZulipTestCase):
for user in test_users:
self.subscribe(user, stream_name)
# Now unsubscribe users from the first few streams,
# so they have to reactivate.
for stream_name in streams[:5]:
for user in test_users:
self.unsubscribe(user, stream_name)
test_user_ids = [user.id for user in test_users]
with queries_captured() as queries:
@ -3292,7 +3298,7 @@ class SubscriptionAPITest(ZulipTestCase):
# The only known O(N) behavior here is that we call
# principal_to_user_profile for each of our users.
self.assert_length(queries, 21)
self.assert_length(queries, 22)
def test_subscriptions_add_for_principal(self) -> None:
"""