-
Notifications
You must be signed in to change notification settings - Fork 1
/
build.gradle.kts
77 lines (64 loc) · 1.86 KB
/
build.gradle.kts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
val spekVersion = "2.0.14"
val kotlinVersion = "1.4.20"
plugins {
kotlin("jvm") version "1.4.20"
}
buildscript {
repositories {
maven("https://plugins.gradle.org/m2/")
}
dependencies {
classpath("org.junit.platform:junit-platform-gradle-plugin:1.0.0")
classpath("org.jlleitschuh.gradle:ktlint-gradle:9.4.1")
}
}
allprojects {
repositories {
jcenter()
}
}
subprojects {
apply(plugin = "kotlin")
apply(plugin = "org.jlleitschuh.gradle.ktlint") // Version should be inherited from parent
// Optionally configure plugin
configure<org.jlleitschuh.gradle.ktlint.KtlintExtension> {
debug.set(true)
disabledRules.set(setOf("no-wildcard-imports"))
}
dependencies {
testImplementation("org.spekframework.spek2:spek-dsl-jvm:$spekVersion")
testRuntimeOnly("org.spekframework.spek2:spek-runner-junit5:$spekVersion")
testRuntimeOnly("org.jetbrains.kotlin:kotlin-reflect:$kotlinVersion")
testImplementation("io.strikt:strikt-core:0.28.0")
implementation(kotlin("stdlib-jdk8"))
}
tasks.test {
useJUnitPlatform {
includeEngines("spek2")
}
}
tasks.withType<KotlinCompile> {
kotlinOptions {
jvmTarget = "1.8"
}
}
}
tasks.test {
useJUnitPlatform {
includeEngines("spek2")
}
}
// setup dependencies
dependencies {
testImplementation("org.spekframework.spek2:spek-dsl-jvm:$spekVersion")
testRuntimeOnly("org.spekframework.spek2:spek-runner-junit5:$spekVersion")
testRuntimeOnly("org.jetbrains.kotlin:kotlin-reflect:$kotlinVersion")
testImplementation("io.strikt:strikt-core:0.28.0")
implementation(kotlin("stdlib-jdk8"))
}
tasks.withType<KotlinCompile> {
kotlinOptions {
jvmTarget = "1.8"
}
}