コード例 #1
0
 def because_we_add_a_message(self):
     msg = Event(self.message_id, "type", {}, "stream", self.sequence_no)
     asyncio.ensure_future(self.send_message(msg), loop=self._loop)
     self._loop.run_until_complete(self.message_processor.consume_events())
コード例 #2
0
 def because_we_process_a_message(self):
     with (self._log.capture()):
         msg = Event(self.message_id, "message-type", {}, "stream", 2)
         asyncio.ensure_future(self.send_message(msg), loop=self._loop)
         self._loop.run_until_complete(self.event_raiser.start())
コード例 #3
0
ファイル: test_dispatching.py プロジェクト: wuan/atomicpuppy
 def because_we_add_a_message(self):
     msg = Event(self.message_id, "type", {}, "stream", self.sequence_no)
     asyncio. async (self.send_message(msg), loop=self._loop)
     self._loop.run_until_complete(self.message_processor.start())