@Test
    public void shouldFailWithDisallowedHeaders() {
        commonSetup();

        allowHeaders.add("x-monument");

        setRequestHeaders(new String[] { "x-penshaw", "x-monument" } );

        connector = new CorsConnector(request, config, failureFactory);
        HeaderMap responseHeaders = connector.getResponseHeaders();

        Assert.assertTrue(connector.isFailure());
        Assert.assertTrue(!connector.isShortcircuit());
        Assert.assertEquals(null,
                responseHeaders.get(CorsConnector.AC_ALLOW_HEADERS_KEY));
    }
Test preflight aspects of CORS

@author Marc Savy {@literal <msavy@redhat.com>}
plugins/cors-policy/src/test/java/io/apiman/plugins/cors_policy/CorsConnectorPreflightTest.java