summary refs log tree commit diff
path: root/tests/appservice/test_scheduler.py (unfollow)
Commit message (Collapse)AuthorFilesLines
2021-12-01Modify the tests to work with the new flow; clean up tests github/anoa/e2e_as_to_device_dirty anoa/e2e_as_to_device_dirtyAndrew Morgan1-48/+58
This ended up ballooning much larger than intended :/ Part of the reason for the large amount of changes was the elimination of the _ServiceQueuer.enqueue_{event,ephemeral} methods and replacing them with ApplicationServiceScheduler.enqueue_for_appservice. That meant we had to change all of the tests that mock'd enqueue_{event,ephemeral} to instead look lower-level, at the calls to _TransactionController.send. Other than that, there was just the normal amount of adding checks that to_device_messages as an argument to enqueue_for_appservice is filled out correctly. The change to scheduler means that we don't have to keep adding another [] every time we check a call to _TransactionController.send.
2021-12-01fix type hint; make AppServiceTransaction instantiation a bit easierAndrew Morgan3-9/+7
2021-12-01generalise sending application service transactions and allow to-deviceAndrew Morgan5-42/+108
2021-11-24Add comment on why we don't NOT NULL to_device_stream_idAndrew Morgan1-0/+5
2021-11-24Add some FIXME commentsAndrew Morgan1-0/+3
2021-11-24rename set_type_stream_id_for_appservice -> set_appservice_stream_type_posAndrew Morgan4-13/+13
2021-11-22Fix existing unit tests github/anoa/e2e_as anoa/e2e_asAndrew Morgan1-8/+5
There is so much mocking going on here. I look forward to replacing these one day.
2021-11-19Simplify registration of appservices in testsAndrew Morgan1-64/+51
2021-11-19Rename user1, user2 in tests to something more usefulAndrew Morgan1-30/+51
2021-11-19Rename ApplicationServiceEphemeralEventsTestCaseAndrew Morgan1-1/+5
2021-11-19_handle_to_device -> _get_to_device_messagesAndrew Morgan1-3/+7
2021-11-19Deduplicate ephemeral events to send conditionalAndrew Morgan3-28/+34
Test cases needed to be updated, as we now always call submit_ephemeral_events_for_as, it may just be with an empty events list.
2021-11-19Broaden type hints; update commentAndrew Morgan2-5/+7
2021-11-19Move stream filter back into AppserviceHandlerAndrew Morgan2-17/+21
2021-11-19Make msc2409_to_device_messages_enabled private; remove unnecessary checkAndrew Morgan1-6/+3