没有测试的Gradle构建 [英] Gradle build without tests
本文介绍了没有测试的Gradle构建的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我想在不执行单元测试的情况下执行 gradle build
。我试过:
$ p $ $ gradle -Dskip.tests build
这似乎没有做任何事情。有没有其他的命令可以使用?
试试:
<$ c $> $ c>命令行参数,排除任何任务。 c> gradle build -x测试
更新:
Peter的评论中的链接已更改。以下是图。 docs.gradle.org/current/userguide/java_plugin.htmlrel =noreferrer> Gradle用户指南
I want to execute gradle build
without executing the unit tests. I tried:
$ gradle -Dskip.tests build
That doesn't seem to do anything. Is there some other command I could use?
解决方案
You should use the -x
command line argument which excludes any task.
Try:
gradle build -x test
Update:
The link in Peter's comment changed. Here is the diagram from the Gradle user's guide
这篇关于没有测试的Gradle构建的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文