Skip to content

Commit cf81418

Browse files
authored
chore: add docs for enabling logging in unit tests (#339)
1 parent cef5bb7 commit cf81418

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

docs/debugging.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,17 @@ To view low-level request and response log output and the time of the log entry,
2121

2222
The log level can be adjusted up as needed to DEBUG, INFO, WARN, or ERROR. [See here](http://www.slf4j.org/api/org/slf4j/impl/SimpleLogger.html) for all properties for the simple logger.
2323

24+
#### Unit Tests
25+
26+
To enable logging in JVM unit tests, the JVM properties can be passed via the Gradle `test` task. Here is an example snippet from a `build.gradle.kts` file:
27+
28+
```
29+
tasks.test {
30+
options {
31+
jvmArgs = listOf("-Dorg.slf4j.simpleLogger.defaultLogLevel=TRACE", "-Dorg.slf4j.simpleLogger.showDateTime=true")
32+
}
33+
}
34+
```
2435

2536
#### CRT Logs
2637

0 commit comments

Comments
 (0)