Join Slack
Powered by
I'm doing some json formatting of our logs using l...
# kotlin-logging
c
cmgurba
10/18/2018, 2:29 PM
I'm doing some json formatting of our logs using logback config. We use kotlin-logging in our app. Does anybody have an example / doc on how to capture logging output to assert against in a unit test from kotlin-logging?
cmgurba
10/18/2018, 2:30 PM
I was looking at this
https://github.com/MicroUtils/kotlin-logging/blob/master/kotlin-logging-jvm/src/test/kotlin/mu/LoggingTest.kt
, but i'm running into casting issues around the
addAppender
code
o
oshai
10/18/2018, 2:48 PM
The examples you showed are using log4j. there probably should be something similar to logback
oshai
10/18/2018, 2:49 PM
Haven't tried that but there is an example here:
https://dzone.com/articles/unit-testing-asserting-line
26
Views
Open in Slack
Previous
Next