def test_client_receives_servers_data(self):
    '\n        The data the server sends in its callback is received by the client.\n        '
    calls = []

    def server_callback(*args, **kwargs):
        return self.sample_ocsp_data

    def client_callback(conn, ocsp_data, ignored):
        calls.append(ocsp_data)
        return True
    client = self._client_connection(callback=client_callback, data=None)
    server = self._server_connection(callback=server_callback, data=None)
    handshake_in_memory(client, server)
    assert (len(calls) == 1)
    assert (calls[0] == self.sample_ocsp_data)
The data the server sends in its callback is received by the client.
def test_client_receives_servers_data(self):
    '\n        \n        '
    calls = []

    def server_callback(*args, **kwargs):
        return self.sample_ocsp_data

    def client_callback(conn, ocsp_data, ignored):
        calls.append(ocsp_data)
        return True
    client = self._client_connection(callback=client_callback, data=None)
    server = self._server_connection(callback=server_callback, data=None)
    handshake_in_memory(client, server)
    assert (len(calls) == 1)
    assert (calls[0] == self.sample_ocsp_data)