test_presence: Change assert_max_length to assert_length.

This commit is contained in:
Umair Khan 2017-03-31 11:31:18 +05:00 committed by Tim Abbott
parent cc96cefe75
commit 1b8d9f186e
1 changed files with 3 additions and 1 deletions

View File

@ -23,6 +23,7 @@ from zerver.models import (
UserActivity, UserActivity,
UserProfile, UserProfile,
UserPresence, UserPresence,
flush_per_request_caches,
) )
import datetime import datetime
@ -44,10 +45,11 @@ class ActivityTest(ZulipTestCase):
count=count, count=count,
last_visit=last_visit last_visit=last_visit
) )
flush_per_request_caches()
with queries_captured() as queries: with queries_captured() as queries:
self.client_get('/activity') self.client_get('/activity')
self.assert_max_length(queries, 13) self.assert_length(queries, 2)
class TestClientModel(ZulipTestCase): class TestClientModel(ZulipTestCase):
def test_client_stringification(self): def test_client_stringification(self):