-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle.kts
55 lines (47 loc) · 1.44 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
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
val spek_version = "2.0.5"
val kotlin_version = "1.3.21"
plugins {
java
kotlin("jvm") version "1.3.21"
}
group = "in.ashishchaudhary.algorithms"
version = "1.0"
repositories {
mavenCentral()
maven { url = uri("https://dl.bintray.com/spekframework/spek") }
}
dependencies {
implementation(kotlin("stdlib-jdk8"))
implementation(fileTree(mapOf("dir" to "libs", "include" to listOf("*.jar"))))
testImplementation("org.jetbrains.kotlin:kotlin-test-junit5:$kotlin_version")
testImplementation("org.spekframework.spek2:spek-dsl-jvm:$spek_version") {
exclude("org.jetbrains.kotlin")
}
testRuntimeOnly("org.junit.jupiter:junit-jupiter-engine:5.2.0")
testRuntimeOnly("org.spekframework.spek2:spek-runner-junit5:$spek_version") {
exclude("org.junit.platform")
exclude("org.jetbrains.kotlin")
}
testRuntimeOnly("org.jetbrains.kotlin:kotlin-reflect:$kotlin_version")
}
tasks.withType<Test> {
useJUnitPlatform {
includeEngines("spek2")
}
}
sourceSets.getByName("main") {
java.srcDir("src/main/java")
java.srcDir("src/main/kotlin")
}
sourceSets.getByName("test") {
java.srcDir("src/test/kotlin")
resources.srcDir("src/test/resources")
}
configure<JavaPluginConvention> {
sourceCompatibility = JavaVersion.VERSION_1_8
}
tasks.withType<KotlinCompile> {
kotlinOptions.jvmTarget = "1.8"
}
val clean: Delete by tasks