예제 #1
0
  @Test
  public void addsAppVersion() {

    // given
    final ILoggingEvent loggingEvent =
        createLoggingEvent()
            .with(createThrowableProxy())
            .withMdcProperty("appVersion", "someAppVersion");

    // when
    final NotificationVO notification = converter.convertToNotification(loggingEvent);
    final EventVO event = notification.getEvents().get(0);

    // then
    assertThat(event.getAppVersion(), is("someAppVersion"));
  }