def testCallsStoreIfTagCache(self, mock): routes.config('tag', 'elephant') routes.process_outside_message("123", "Hail YESOCH") mock.assert_called_with("elephant", '123', "Hail YESOCH")
def testPanicBypassesMessageSaving(self, mock): routes.config('tag', 'abc') routes.panic() routes.process_outside_message('1234', 'this is tagged') mock.assert_called_with('1234', 'this is tagged')
def testCallsForwardIfNoTagCache(self, mock): routes.process_outside_message("123", "Hail YESOCH") mock.assert_called_with("123", "Hail YESOCH")
def testGetsMessage(self, mock): routes.config('tag', 'abc') routes.process_outside_message('1234', 'this is tagged') output = routes.listen('abc') mock.assert_called_with('1234', 'this is tagged')