test_realm_emoji: Fix some typos.

This commit is contained in:
Harshit Bansal 2017-07-22 19:10:45 +00:00
parent 4737363f0c
commit b683af2cbb
1 changed files with 4 additions and 4 deletions

View File

@ -26,12 +26,12 @@ class RealmEmojiTest(ZulipTestCase):
email = self.example_email('iago') email = self.example_email('iago')
self.login(email) self.login(email)
realm = get_realm('zulip') realm = get_realm('zulip')
RealmEmoji.objects.create(realm=realm, name='my_emojy', file_name='my_emojy') RealmEmoji.objects.create(realm=realm, name='my_emoji', file_name='my_emoji')
result = self.client_get("/json/realm/emoji") result = self.client_get("/json/realm/emoji")
self.assert_json_success(result) self.assert_json_success(result)
content = ujson.loads(result.content) content = ujson.loads(result.content)
self.assertEqual(len(content["emoji"]), 2) self.assertEqual(len(content["emoji"]), 2)
self.assertIsNone(content["emoji"]['my_emojy']['author']) self.assertIsNone(content["emoji"]['my_emoji']['author'])
def test_list_admins_only(self): def test_list_admins_only(self):
# type: () -> None # type: () -> None
@ -40,12 +40,12 @@ class RealmEmojiTest(ZulipTestCase):
realm = get_realm('zulip') realm = get_realm('zulip')
realm.add_emoji_by_admins_only = True realm.add_emoji_by_admins_only = True
realm.save() realm.save()
check_add_realm_emoji(realm, 'my_emojy', 'my_emojy') check_add_realm_emoji(realm, 'my_emoji', 'my_emoji')
result = self.client_get("/json/realm/emoji") result = self.client_get("/json/realm/emoji")
self.assert_json_success(result) self.assert_json_success(result)
content = ujson.loads(result.content) content = ujson.loads(result.content)
self.assertEqual(len(content["emoji"]), 2) self.assertEqual(len(content["emoji"]), 2)
self.assertIsNone(content["emoji"]['my_emojy']['author']) self.assertIsNone(content["emoji"]['my_emoji']['author'])
def test_upload(self): def test_upload(self):
# type: () -> None # type: () -> None