def test_direct_send_receive(self):
        conn = self.rpc.create_connection()
        message = 'direct test message'

        self.received_message = None

        def _callback(message):
            self.received_message = message

        conn.declare_direct_consumer('a_direct', _callback)
        conn.direct_send('a_direct', message)
        conn.consume(limit=1)
        conn.close()

        self.assertEqual(self.received_message, message)
What to do when a message is received.
dataset/ETHPy150Open nii-cloud/dodai-compute/nova/tests/test_rpc_kombu.py/RpcKombuTestCase.test_direct_send_receive--crossover with--dataset/ETHPy150Open celery/cell/cell/actors.py/Actor._on_message