@Test
    void requireThatMultipleHostHeadersReturns400() throws Exception {
        var metricConsumer = new MetricConsumerMock();
        JettyTestDriver driver = JettyTestDriver.newConfiguredInstance(
                mockRequestHandler(),
                new ServerConfig.Builder().metric(new ServerConfig.Metric.Builder().reporterEnabled(false)),
                new ConnectorConfig.Builder(),
                binder -> binder.bind(MetricConsumer.class).toInstance(metricConsumer.mockitoMock()));
        driver.client()
                .newGet("/status.html").addHeader("Host", "localhost").addHeader("Host", "vespa.ai").execute()
                .expectStatusCode(is(BAD_REQUEST)).expectContent(containsString("HTTP ERROR 400 Duplicate Host Header"));
        var aggregator = MetricAggregatingRequestLog.getBean(driver.server());
        var metric = waitForStatistics(aggregator);
        assertEquals(400, metric.dimensions.statusCode);
        assertEquals("GET", metric.dimensions.method);
        assertTrue(driver.close());
    }
@author Oyvind Bakksjo
@author Simon Thoresen Hult
@author bjorncs
container-core/src/test/java/com/yahoo/jdisc/http/server/jetty/HttpServerTest.java