def test_move_by_idmap(): with patch('celery.contrib.migrate.move') as move: move_by_idmap({'123f': Queue('foo')}) move.assert_called() cb = move.call_args[0][0] body = {'id': '123f'} assert cb(body, Message(body))
def test_move_by_idmap(self): with patch('celery.contrib.migrate.move') as move: move_by_idmap({'123f': Queue('foo')}) move.assert_called() cb = move.call_args[0][0] self.assertTrue(cb({'id': '123f'}, Mock()))
def test_move_by_idmap(self): with patch('celery.contrib.migrate.move') as move: move_by_idmap({'123f': Queue('foo')}) self.assertTrue(move.called) cb = move.call_args[0][0] self.assertTrue(cb({'id': '123f'}, Mock()))
def test_move_by_idmap(): with patch("celery.contrib.migrate.move") as move: move_by_idmap({"123f": Queue("foo")}) move.assert_called() cb = move.call_args[0][0] assert cb({"id": "123f"}, Mock())
def test_move_by_idmap(): with patch('celery.contrib.migrate.move') as move: move_by_idmap({'123f': Queue('foo')}) move.assert_called() cb = move.call_args[0][0] assert cb({'id': '123f'}, Mock())