pitest / pitest-junit5-plugin

JUnit 5 test framework support for Pitest
Apache License 2.0
74 stars 27 forks source link

Plugin crashes when `junit-jupiter-engine` dependency is not explicitly declared #105

Open Stephan202 opened 8 months ago

Stephan202 commented 8 months ago

After merging PicnicSupermarket/error-prone-support#973, in which explicit test dependencies on junit-jupiter-engine were dropped (since Surefire anyway provides the test framework implementation based on an analysis of the test classpath), we noticed that Pitest started failing. See PicnicSupermarket/error-prone-support#972 for an example. Reported output:

[ERROR] Failed to execute goal org.pitest:pitest-maven:1.15.3:mutationCoverage (default-cli) on project documentation-support: Execution default-cli of goal org.pitest:pitest-maven:1.15.3:mutationCoverage failed: Coverage generation minion exited abnormally! (UNKNOWN_ERROR)
[ERROR] 
[ERROR] Please copy and paste the information and the complete stacktrace below when reporting an issue
[ERROR] VM : OpenJDK 64-Bit Server VM
[ERROR] Vendor : Eclipse Adoptium
[ERROR] Version : 17.0.9+9
[ERROR] Uptime : 3318
[ERROR] Input -> 
[ERROR]  1 : -XX:ReservedCodeCacheSize=512m
[ERROR]  2 : -XX:SoftRefLRUPolicyMSPerMB=10
[ERROR]  3 : -XX:+UseParallelGC
[ERROR]  4 : --add-exports=jdk.compiler/com.sun.tools.javac.api=ALL-UNNAMED
[ERROR]  5 : --add-exports=jdk.compiler/com.sun.tools.javac.code=ALL-UNNAMED
[ERROR]  6 : --add-exports=jdk.compiler/com.sun.tools.javac.file=ALL-UNNAMED
[ERROR]  7 : --add-exports=jdk.compiler/com.sun.tools.javac.main=ALL-UNNAMED
[ERROR]  8 : --add-exports=jdk.compiler/com.sun.tools.javac.model=ALL-UNNAMED
[ERROR]  9 : --add-exports=jdk.compiler/com.sun.tools.javac.parser=ALL-UNNAMED
[ERROR]  10 : --add-exports=jdk.compiler/com.sun.tools.javac.processing=ALL-UNNAMED
[ERROR]  11 : --add-exports=jdk.compiler/com.sun.tools.javac.tree=ALL-UNNAMED
[ERROR]  12 : --add-exports=jdk.compiler/com.sun.tools.javac.util=ALL-UNNAMED
[ERROR]  13 : --add-opens=jdk.compiler/com.sun.tools.javac.comp=ALL-UNNAMED
[ERROR]  14 : -Dclassworlds.conf=/home/user/.sdkman/candidates/maven/current/bin/m2.conf
[ERROR]  15 : -Dmaven.home=/home/user/.sdkman/candidates/maven/current
[ERROR]  16 : -Dlibrary.jansi.path=/home/user/.sdkman/candidates/maven/current/lib/jansi-native
[ERROR]  17 : -Dmaven.multiModuleProjectDirectory=/path/to/error-prone-support
[ERROR] BootClassPathSupported : false

In our case the cause was not so hard to determine, but it could be a real head-scratcher if this issue happens when a user introduces Pitest for the first time. So the question is: can the plugin be updated to mirror whatever Surefire does?