Skip to content

Commit

Permalink
test_subs/test_users: Fix breaking tests due to regressions.
Browse files Browse the repository at this point in the history
  • Loading branch information
adnrs96 committed Jul 12, 2017
1 parent 5acc750 commit 6100d43
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions zerver/tests/test_subs.py
Original file line number Diff line number Diff line change
Expand Up @@ -1363,9 +1363,9 @@ def test_successful_subscriptions_add_with_announce(self):
other_params = {
'announce': 'true',
}
notifications_stream = get_stream(self.streams[0], self.realm)
self.realm.notifications_stream = notifications_stream
self.realm.save()
notifications_stream = get_stream(self.streams[0], self.test_realm)
self.test_realm.notifications_stream = notifications_stream
self.test_realm.save()

# Delete the UserProfile from the cache so the realm change will be
# picked up
Expand Down
2 changes: 1 addition & 1 deletion zerver/tests/test_users.py
Original file line number Diff line number Diff line change
Expand Up @@ -388,10 +388,10 @@ def test_get_pointer(self):
self.assertIn("pointer", json)

def test_cache_behavior(self):
# type: () -> None
"""Tests whether fetching a user object the normal way, with
`get_user`, makes 1 cache query and 1 database query.
"""
# type: () -> None
realm = get_realm("zulip")
email = self.example_email("hamlet")
with queries_captured() as queries:
Expand Down

0 comments on commit 6100d43

Please sign in to comment.