mirror of
https://github.com/zulip/zulip.git
synced 2025-11-07 15:33:30 +00:00
Reorganize sections of test_realm_scenarios().
This change groups the positive scenarios together and likewise for the negative scenarios.
This commit is contained in:
@@ -111,14 +111,6 @@ class TestCrossRealmPMs(ZulipTestCase):
|
||||
self.assertEqual(len(messages), 1)
|
||||
self.assertEquals(messages[0].sender.pk, user1.pk)
|
||||
|
||||
"""Users on the different realms can not PM each other"""
|
||||
with assert_disallowed():
|
||||
self.send_message(user1_email, user2_email, Recipient.PERSONAL)
|
||||
|
||||
"""Users on three different realms can not PM each other"""
|
||||
with assert_disallowed():
|
||||
self.send_message(user1_email, [user2_email, user3_email], Recipient.PERSONAL)
|
||||
|
||||
"""OG Users in the zulip.com realm can PM any realm"""
|
||||
self.send_message(cross_email, user2_email, Recipient.PERSONAL)
|
||||
|
||||
@@ -140,6 +132,14 @@ class TestCrossRealmPMs(ZulipTestCase):
|
||||
self.send_message(user1_email, [user2_email, cross_email],
|
||||
Recipient.PERSONAL)
|
||||
|
||||
# Users on the different realms can not PM each other
|
||||
with assert_disallowed():
|
||||
self.send_message(user1_email, user2_email, Recipient.PERSONAL)
|
||||
|
||||
# Users on three different realms can not PM each other
|
||||
with assert_disallowed():
|
||||
self.send_message(user1_email, [user2_email, user3_email], Recipient.PERSONAL)
|
||||
|
||||
class PersonalMessagesTest(ZulipTestCase):
|
||||
|
||||
def test_auto_subbed_to_personals(self):
|
||||
|
||||
Reference in New Issue
Block a user