'Creates a L{HostnameEndpoint} instance where the hostname is
resolved into a single IPv6 address.
@param reactor: The L{MemoryReactor}
@param clientFactory: The client L{IProtocolFactory}
@param connectArgs: Additional arguments to
L{HostnameEndpoint.connect}
@return: A L{tuple} of the form C{(endpoint, (expectedAddress,
expectedPort, clientFactory, timeout, localBindAddress,
hostnameAddress))}'

def createClientEndpoint(self, reactor, clientFactory, **connectArgs):

    expectedAddress = '1:2::3:4'
    address = HostnameAddress('ipv6.example.com', 80)
    endpoint = endpoints.HostnameEndpoint(reactor, 'ipv6.example.com', address.port, **connectArgs)
    def fakegetaddrinfo(host, port, family, socktype):
        return [(AF_INET6, SOCK_STREAM, IPPROTO_TCP, '', (expectedAddress, 80))]
    endpoint._getaddrinfo = fakegetaddrinfo
    endpoint._deferToThread = self.synchronousDeferredToThread
    return (endpoint, (expectedAddress, address.port, clientFactory, connectArgs.get('timeout', 30), connectArgs.get('bindAddress', None)), address)
