[英]How to configure nebula.integtest with gradle project's integration tests ( kotlin DSL)?
I wanna separate integration from unit tests in my gradle kotlin dsl project build ( the project itself written on java).我想在我的 gradle kotlin dsl 项目构建(项目本身用 java 编写)中将集成与单元测试分开。 There are many answers here how to configure source set etc.
这里有很多答案如何配置源集等。
But I came across nebula.integtest plugin ( I hope it's well known plugin to don't blame me in promoting it)但是我遇到了nebula.integtest 插件(我希望它是众所周知的插件,不要怪我推广它)
But there is quite poor manual there, just:但是那里的手册很差,只是:
plugins {
id "nebula.integtest" version "8.0.0"
}
is it really all what need to be done?这真的是所有需要做的事情吗? Which folder should contain integration tests then?
那么哪个文件夹应该包含集成测试?
This is documented in the README
of the project (emphasis mine):这记录在项目的
README
文件中(重点是我的):
https://github.com/nebula-plugins/nebula-project-plugin#nebula-facet-plugin https://github.com/nebula-plugins/nebula-project-plugin#nebula-facet-plugin
A corrolary from the Facet Plugin is a concrete Facet, this plugin provides one specifically for Integration Tests.
Facet Plugin 的一个推论是一个具体的 Facet,这个插件专门为集成测试提供了一个。 By applying this plugin, you'll get an
integrationTest
Test task, where sources go insrc/integTest/java
and dependencies can go intointegTestImplementation
andintegTestRuntimeOnly
(which extend from the test SourceSet), with the 'check' task depending on the task.通过应用此插件,您将获得一个
integrationTest
测试任务,其中源位于src/integTest/java
,依赖项可以进入integTestImplementation
和integTestRuntimeOnly
(从测试 SourceSet 扩展),“检查”任务取决于任务. To apply the plugin:要应用插件:
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.