@Test
    public void testFilter() {
        ServerWebExchange exchangeNoHeader = MockServerWebExchange.from(MockServerHttpRequest
                .get("http://localhost:8080")
                .build());
        WebFilterChain chainNoHeader = mock(WebFilterChain.class);
        when(chainNoHeader.filter(exchangeNoHeader)).thenReturn(Mono.empty());
        CrossFilter filterNoHeader = new CrossFilter(new CrossFilterConfig());
        StepVerifier.create(filterNoHeader.filter(exchangeNoHeader, chainNoHeader))
                .expectSubscription()
                .verifyComplete();

        ServerWebExchange exchangeNormal = MockServerWebExchange.from(MockServerHttpRequest
                .get("http://localhost:8080")
                .header("Origin", "test")
                .build());
        WebFilterChain chainNormal = mock(WebFilterChain.class);
        when(chainNormal.filter(exchangeNormal)).thenReturn(Mono.empty());
        CrossFilter filterNormal = new CrossFilter(new CrossFilterConfig());
        StepVerifier.create(filterNormal.filter(exchangeNormal, chainNormal))
                .expectSubscription()
                .verifyComplete();

        ServerWebExchange exchangeOption = MockServerWebExchange.from(MockServerHttpRequest
                .options("http://localhost:8080")
                .header("Origin", "test")
                .build());
        WebFilterChain chainOption = mock(WebFilterChain.class);
        when(chainOption.filter(exchangeOption)).thenReturn(Mono.empty());
        CrossFilter filterOption = new CrossFilter(new CrossFilterConfig());
        StepVerifier.create(filterOption.filter(exchangeOption, chainOption))
                .expectSubscription()
                .verifyComplete();
    }
test method for {@link CrossFilter#filter(ServerWebExchange, WebFilterChain)}.
shenyu-web/src/test/java/org/apache/shenyu/web/filter/CrossFilterTest.java