test_messages: Don’t mock an unused import.

Since 8a1794caa3, we don't do any
caching in that system.

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
This commit is contained in:
Anders Kaseorg 2019-02-02 15:15:24 -08:00 committed by Tim Abbott
parent 023f8a0def
commit 4e0a79d146
2 changed files with 2 additions and 3 deletions

View File

@ -16,7 +16,7 @@ from zerver.lib.cache import (
generic_bulk_cached_fetch,
to_dict_cache_key,
to_dict_cache_key_id,
cache_get, cache_set,
cache_set,
)
from zerver.lib.request import JsonableError
from zerver.lib.stream_subscription import (

View File

@ -4132,7 +4132,6 @@ class MessageVisibilityTest(ZulipTestCase):
RealmCount.objects.create(realm=realm, property=stat.property,
end_time=end_time, value=5)
with mock.patch('zerver.lib.message.cache_get', return_value=True), \
mock.patch("zerver.lib.message.update_first_visible_message_id") as m:
with mock.patch("zerver.lib.message.update_first_visible_message_id") as m:
maybe_update_first_visible_message_id(realm, lookback_hours)
m.assert_called_once_with(realm)