@Test
public void shouldAddServiceContextNameToRequestDataMdcLogging() throws Exception {

    final InvocationContext invocationContext = mock(InvocationContext.class);
    when(serviceContextNameProvider.getServiceContextName()).thenReturn("exampleService");
    when(invocationContext.proceed()).thenAnswer(invocationOnMock -> {
        assertThat(MDC.get(REQUEST_DATA), isJson(allOf(
                withJsonPath("$.serviceContext", equalTo("exampleService"))
        )));
        return null;
    });
    mdcLoggerInterceptor.addRequestDataToMdc(invocationContext);
    assertThat(MDC.get(REQUEST_DATA), nullValue());
}