@ParameterizedTest
    @ArgumentsSource(SslTransportLayerArgumentsProvider.class)
    public void testValidEndpointIdentificationSanDns(Args args) throws Exception {
        createSelector(args);
        String node = "0";
        server = createEchoServer(args, SecurityProtocol.SSL);
        args.sslClientConfigs.put(SslConfigs.SSL_ENDPOINT_IDENTIFICATION_ALGORITHM_CONFIG, "HTTPS");
        createSelector(args.sslClientConfigs);
        InetSocketAddress addr = new InetSocketAddress("localhost", server.port());
        selector.connect(node, addr, BUFFER_SIZE, BUFFER_SIZE);

        NetworkTestUtils.checkClientConnection(selector, node, 100, 10);
        server.verifyAuthenticationMetrics(1, 0);
    }
Tests that server certificate with SubjectAltName containing the valid hostname
is accepted by a client that connects using the hostname and validates server endpoint.
clients/src/test/java/org/apache/kafka/common/network/SslTransportLayerTest.java