aboutsummaryrefslogtreecommitdiffstats
path: root/build/export_generators/ide-gradle/test.jinja
blob: fcfcd8f93e0db99ecda3983fd034338a0d02d488 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
{%- if has_test %}
val testsJar by tasks.registering(Jar::class) {
    dependsOn(JavaPlugin.COMPILE_TEST_JAVA_TASK_NAME)
    archiveClassifier.set("tests")
    from(sourceSets["test"].output)
}

artifacts.add(configurations.create("testArtifacts").name, testsJar)

tasks.test {
    testLogging {
        showStandardStreams = true
        events("passed", "skipped", "failed")
    }
}
{%  endif -%}

{%- if has_junit5_test %}
tasks.named<Test>("test") {
    useJUnitPlatform()
}
{%  endif -%}