summary refs log tree commit diff
path: root/tests/storage/test_event_push_actions.py
diff options
context:
space:
mode:
authorEric Eastwood <erice@element.io>2022-08-09 14:50:10 -0500
committerEric Eastwood <erice@element.io>2022-08-09 14:50:10 -0500
commit2a467fd26b369d937a04da950d9ecaf8f23aa382 (patch)
treef2c9f654a0f67d7bbcdf459b9b4a918923d041ca /tests/storage/test_event_push_actions.py
parentOnly set attribute if going forward (diff)
parentMerge branch 'develop' into madlittlemods/11850-migrate-to-opentelemetry (diff)
downloadsynapse-2a467fd26b369d937a04da950d9ecaf8f23aa382.tar.xz
Merge branch 'madlittlemods/11850-migrate-to-opentelemetry' into madlittlemods/13356-messages-investigation-scratch-v1
Conflicts:
	pyproject.toml
	synapse/logging/tracing.py
Diffstat (limited to 'tests/storage/test_event_push_actions.py')
-rw-r--r--tests/storage/test_event_push_actions.py15
1 files changed, 15 insertions, 0 deletions
diff --git a/tests/storage/test_event_push_actions.py b/tests/storage/test_event_push_actions.py

index ba40124c8a..62fd4aeb2f 100644 --- a/tests/storage/test_event_push_actions.py +++ b/tests/storage/test_event_push_actions.py
@@ -135,7 +135,22 @@ class EventPushActionsStoreTestCase(HomeserverTestCase): _assert_counts(1, 1, 0) # Delete old event push actions, this should not affect the (summarised) count. + # + # All event push actions are kept for 24 hours, so need to move forward + # in time. + self.pump(60 * 60 * 24) self.get_success(self.store._remove_old_push_actions_that_have_rotated()) + # Double check that the event push actions have been cleared (i.e. that + # any results *must* come from the summary). + result = self.get_success( + self.store.db_pool.simple_select_list( + table="event_push_actions", + keyvalues={"1": 1}, + retcols=("event_id",), + desc="", + ) + ) + self.assertEqual(result, []) _assert_counts(1, 1, 0) _mark_read(last_event_id)