def test_regular_call(self):
        self.client.connected = mock.Mock()
        self.client.connected.get = mock.Mock(side_effect=lambda ident: True)
        self.client.send_params = mock.Mock()

        req_id = b"some id"
        params = defaultdict(lambda: None, req_id=req_id, command="call")
        result = {"req_id": req_id, "return": "x",
                  "exception": TestException(), "exception_format": ""}

        def wait(exc):
            self.assertEqual(exc, snakemq.rpc.PartialCall)
            self.client.store_result(result)

        with mock.patch.object(snakemq.rpc.Wait, "__call__") as wait_mock:
            wait_mock.side_effect = wait

            # respond is OK
            result["ok"] = True
            self.assertEqual(result["return"],
                  self.client.remote_request("some ident", self.proxy.some_method,
                                              params))
            self.assertEqual(self.client.waiting_for_result, set())
            self.assertEqual(self.client.results, {})

            # respond is an exception
            result["ok"] = False
            self.assertRaises(TestException, self.client.remote_request,
                                  "some ident", self.proxy.some_method, params)
            self.assertEqual(self.client.waiting_for_result, set())
            self.assertEqual(self.client.results, {})

    ##############################################################
Returns a tuple containing a queryset to implement the search,
dataset/ETHPy150Open dsiroky/snakemq/tests/unittests/tests_rpc.py/TestRpcClient.test_regular_call--crossover with--dataset/ETHPy150Open cloudera/hue/desktop/core/ext-py/Django-1.6.10/django/contrib/admin/options.py/ModelAdmin.get_search_results