From 2a052728fdad573cf091f1d25b745324127caa50 Mon Sep 17 00:00:00 2001 From: Will Hunt Date: Fri, 9 Oct 2020 09:25:10 +0100 Subject: [PATCH] Add a single test --- tests/appservice/test_scheduler.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/tests/appservice/test_scheduler.py b/tests/appservice/test_scheduler.py index 8742f5bee8..a3440b937b 100644 --- a/tests/appservice/test_scheduler.py +++ b/tests/appservice/test_scheduler.py @@ -259,3 +259,10 @@ class ApplicationServiceSchedulerQueuerTestCase(unittest.TestCase): srv_2_defer.callback(srv2) self.txn_ctrl.send.assert_called_with(srv2, [srv_2_event2], None) self.assertEquals(3, self.txn_ctrl.send.call_count) + + def test_send_single_ephemeral_no_queue(self): + # Expect the event to be sent immediately. + service = Mock(id=4, name="service") + event = Mock(name="event") + self.queuer.enqueue_ephemeral(service, event) + self.txn_ctrl.send.assert_called_once_with(service, [], event)