@Test
public void publishesSingletonExceptionMapper() {

    ExceptionMapper exceptionMapper = new RuntimeExceptionMapper();
    Application application = mock(Application.class);
    when(application.getSingletons()).thenReturn(newHashSet(exceptionMapper));
    publisher.publish(application);
    verify(providers).addExceptionMapper(exceptionMapper);
}