Package com.reallifedeveloper.tools.test
Class LogbackTestUtil
java.lang.Object
com.reallifedeveloper.tools.test.LogbackTestUtil
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final String
The name of theListAppender
in the Logback configuration, logback-test.xml. -
Method Summary
Modifier and TypeMethodDescriptionstatic void
Clears the list of logging events reteurned bygetLoggingEvents()
.static List<ch.qos.logback.classic.spi.ILoggingEvent>
Gives a list of all logging events generated since startup or the latest call toclearLoggingEvents()
.
-
Field Details
-
LIST_APPENDER_NAME
The name of theListAppender
in the Logback configuration, logback-test.xml.- See Also:
-
-
Method Details
-
getLoggingEvents
Gives a list of all logging events generated since startup or the latest call toclearLoggingEvents()
.This assumes that we are using Logback for logging, with a
ch.qos.logback.core.read.ListAppender
configured for the root logger.- Returns:
- a list of logging events
-
clearLoggingEvents
public static void clearLoggingEvents()Clears the list of logging events reteurned bygetLoggingEvents()
.
-