当maven-compiler-plugin:3.8.0:testCompile @ foo-child运行时,线程转储显示容易出错的时间非常长。我相信有一个错误易犯的错误,但就目前而言,我宁愿不在单元测试上运行错误倾向。
我有一个家长pom.xml:
<modules>
<module>foo-child</module>
</modules>
<dependencyManagement>
<dependency>
<groupId>com.google.errorprone</groupId>
<artifactId>error_prone_annotations</artifactId>
</dependency>
// also has dependency for io.norberg auto-matter and com.google.auto.value auto-value
</dependencyManagement>
<build>
<plugins>
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
// also has annotationProcessorPaths configuration for auto-matter and auto-value
</plugin>
</plugins>
</build>在foo pom.xml中有什么可以让我完全排除运行maven-compiler-plugin:3.8.0:testCompile @ foo-child的东西吗?
我不能完全排除错误倾向,因为像番石榴这样的其他东西都依赖于它。
编辑:似乎 这 用户正在试图解决同样的问题。你知道我怎样才能把给出的解决方案应用到我的案件中吗?
发布于 2019-04-21 05:45:57
使用错误倾向的命令行标志禁用检查:-XepDisableAllChecks
类似的回答用于禁用bazel中容易出错的
将-javacopt=“-XepDisableAllChecks”添加到bazelrc中
对于特定的测试,请使用-XepExcludedPaths
您可以通过-XepExcludedPaths标志从任何容易出错的检查中完全排除某些路径。 -XepExcludedPaths:.*/构建/生成/.*
发布于 2019-04-20 20:18:23
您可以为此使用测试的包含与排除插件。
发布于 2019-04-20 20:19:38
您可以将-XepExcludedPaths编译器选项添加到maven构建中。
https://stackoverflow.com/questions/55752364
复制相似问题