I\'m using Robolectric to test Android. I\'m running my tests via maven, e.g.
mvn -Dtest=LogTest test
If I have code that writes to the logs,
When running tests with maven all you need is something like this :
org.apache.maven.plugins
maven-surefire-plugin
2.17
stdout
When running the tests locally, e.g. in intellij, then all you need is an environmental variable: Just go (for intellij) to Run/Debug Configurations --> Defaults -->Junit --> VM options and add
-Drobolectric.logging=stdout