def test_opaque_data_is_passed_through(self):
    '\n        Both callbacks receive an opaque, user-provided piece of data in their\n        callbacks as the final argument.\n        '
    calls = []

    def server_callback(*args):
        calls.append(args)
        return self.sample_ocsp_data

    def client_callback(*args):
        calls.append(args)
        return True
    sentinel = object()
    client = self._client_connection(callback=client_callback, data=sentinel)
    server = self._server_connection(callback=server_callback, data=sentinel)
    handshake_in_memory(client, server)
    assert (len(calls) == 2)
    assert (calls[0][(- 1)] is sentinel)
    assert (calls[1][(- 1)] is sentinel)
Both callbacks receive an opaque, user-provided piece of data in their
callbacks as the final argument.
def test_opaque_data_is_passed_through(self):
    '\n        Both callbacks receive an opaque, user-provided piece of data in their\n        callbacks as the final argument.\n        '
    calls = []

    def server_callback(*args):
        calls.append(args)
        return self.sample_ocsp_data

    def client_callback(*args):
        calls.append(args)
        return True
    sentinel = object()
    client = self._client_connection(callback=client_callback, data=sentinel)
    server = self._server_connection(callback=server_callback, data=sentinel)
    handshake_in_memory(client, server)
    assert (len(calls) == 2)
    assert (calls[0][(- 1)] is sentinel)
    assert (calls[1][(- 1)] is sentinel)