mirror of
https://github.com/zulip/zulip.git
synced 2025-11-03 05:23:35 +00:00
user_groups: Move constants for system group names to a new class.
This commit moves constants for system group names to a new "SystemGroups" class so that we can use these group names in multiple classes in models.py without worrying about the order of defining them.
This commit is contained in:
@@ -35,6 +35,7 @@ from zerver.models import (
|
||||
Message,
|
||||
Realm,
|
||||
Stream,
|
||||
SystemGroups,
|
||||
UserGroup,
|
||||
UserMessage,
|
||||
UserProfile,
|
||||
@@ -2425,7 +2426,7 @@ class EditMessageTest(EditMessageTestCase):
|
||||
support = check_add_user_group(othello.realm, "support", [othello], acting_user=None)
|
||||
|
||||
moderators_system_group = UserGroup.objects.get(
|
||||
realm=iago.realm, name=UserGroup.MODERATORS_GROUP_NAME, is_system_group=True
|
||||
realm=iago.realm, name=SystemGroups.MODERATORS, is_system_group=True
|
||||
)
|
||||
|
||||
self.login("cordelia")
|
||||
|
||||
Reference in New Issue
Block a user