升级pdfbox依赖版本后测试覆盖率变为0
jiangxincode opened this issue · 1 comments
jiangxincode commented
从以下修改之后:cdead78
coverall.io显示的覆盖率降为0:
https://coveralls.io/builds/64326402
本地使用mvn clean test
测试,
升级之前
[INFO] --- maven-surefire-plugin:3.2.5:test (default-test) @ ApkToolBoxGUI ---
[INFO] Using auto detected provider org.apache.maven.surefire.junit4.JUnit4Provider
升级之后
[INFO] --- maven-surefire-plugin:3.2.5:test (default-test) @ ApkToolBoxGUI ---
[INFO] Using auto detected provider org.apache.maven.surefire.junitplatform.JUnitPlatformProvider
使用mvn dependency:tree
打印依赖关系,差别如下:
原因是pdfbox中依赖了junit-platform-xxx
,导致maven-surefire-plugin
插件自动选择Provider
为org.apache.maven.surefire.junitplatform.JUnitPlatformProvider
而不是之前的org.apache.maven.surefire.junit4.JUnit4Provider
结合maven-surefire-plugin
介绍显示指定Provider:
https://maven.apache.org/surefire/maven-surefire-plugin/examples/providers.html
jiangxincode commented
see also:
1b51d8b