This repository was archived by the owner on Apr 26, 2024. It is now read-only.
Commit bbafc91 David Robertson
committed
1 parent f012474 commit bbafc91 Copy full SHA for bbafc91
File tree 1 file changed +6
-0
lines changed
1 file changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -96,8 +96,12 @@ def test_initialise_reserved_users(self):
96
96
97
97
# Test each of the registered users is marked as active
98
98
timestamp = self .get_success (self .store .user_last_seen_monthly_active (user1 ))
99
+ # Mypy notes that one shouldn't compare Optional[int] to 0 with assertGreater.
100
+ # Check that timestamp really is an int.
101
+ assert timestamp is not None
99
102
self .assertGreater (timestamp , 0 )
100
103
timestamp = self .get_success (self .store .user_last_seen_monthly_active (user2 ))
104
+ assert timestamp is not None
101
105
self .assertGreater (timestamp , 0 )
102
106
103
107
# Test that users with reserved 3pids are not removed from the MAU table
@@ -166,9 +170,11 @@ def test_user_last_seen_monthly_active(self):
166
170
self .get_success (self .store .upsert_monthly_active_user (user_id2 ))
167
171
168
172
result = self .get_success (self .store .user_last_seen_monthly_active (user_id1 ))
173
+ assert result is not None
169
174
self .assertGreater (result , 0 )
170
175
171
176
result = self .get_success (self .store .user_last_seen_monthly_active (user_id3 ))
177
+ assert result is not None
172
178
self .assertNotEqual (result , 0 )
173
179
174
180
@override_config ({"max_mau_value" : 5 })
You can’t perform that action at this time.
0 commit comments