  @Test
  public void testInitWithNonDefaultParameter() throws Exception {


    // setup
    DiagnosticContextFilter filter = new DiagnosticContextFilter();
    String field = (String) ReflectionTestUtils.getField(DiagnosticContextFilter.class,
        CORRELATION_ID_HEADER_NAME_PARAM_FIELD_NAME);
    assertThat(field).isNotNull();
    String nonDefaultParameter = "test";
    when(this.config.getInitParameter(field)).thenReturn(nonDefaultParameter);

    // exercise
    filter.init(this.config);
    // verify
    String correlationIdHttpHeaderName = (String) ReflectionTestUtils.getField(filter,
        CORRELATION_ID_HEADER_NAME_PARAM);
    assertThat(correlationIdHttpHeaderName).isEqualTo(nonDefaultParameter);
  }