The stactrace output by the unit test is truncated and not useful because of that. I don't have access to the surefire reports and the majority of the logs are suppressed because of the log level set in the command below. I also can't change the mvn command.
How do I disable stactrace trimming with the current limitations?
Command:
mvn -B -ntp -s settings.xml clean org.jacoco:jacoco-maven-plugin:0.8.7:prepare-agent test org.jacoco:jacoco-maven-plugin:0.8.7:report -Dcheckstyle.skip -Dorg.slf
4j.simpleLogger.defaultLogLevel=warn
Log Output:
[ERROR] Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 0.015 s <<< FAILURE! - in ****.controller.RealmAdminControllerTest
[ERROR] test Time elapsed: 0.013 s <<< ERROR!
java.lang.NullPointerException
at ***.controller.RealmAdminControllerTest.test(RealmAdminControllerTest.java:18)
I've tried adding trimStackTrace = false to the surefire & failsafe plugins without any luck (individually and as a group):
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<configuration>
<append>true</append>
<trimStackTrace>false</trimStackTrace>
</configuration>
<executions>
<execution>
<id>default-prepare-agent</id>
<goals>
<goal>prepare-agent</goal>
</goals>
</execution>
<execution>
<id>default-report</id>
<goals>
<goal>prepare-agent-integration</goal>
</goals>
</execution>
<execution>
<id>jacoco-site</id>
<phase>verify</phase>
<goals>
<goal>report</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-failsafe-plugin</artifactId>
<configuration>
<trimStackTrace>false</trimStackTrace>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-report-plugin</artifactId>
<configuration>
<trimStackTrace>false</trimStackTrace>
</configuration>
</plugin>