2024-05-09 14:48:56 +02:00
|
|
|
import org.jetbrains.intellij.platform.gradle.TestFrameworkType
|
|
|
|
|
2024-02-07 15:04:10 +01:00
|
|
|
/*
|
|
|
|
* Copyright 2003-2024 The IdeaVim authors
|
|
|
|
*
|
|
|
|
* Use of this source code is governed by an MIT-style
|
|
|
|
* license that can be found in the LICENSE.txt file or at
|
|
|
|
* https://opensource.org/licenses/MIT.
|
|
|
|
*/
|
|
|
|
|
|
|
|
plugins {
|
|
|
|
id("java")
|
|
|
|
kotlin("jvm")
|
2024-05-09 14:48:56 +02:00
|
|
|
id("org.jetbrains.intellij.platform.module")
|
2024-02-07 15:04:10 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
val kotlinVersion: String by project
|
2024-05-09 14:48:56 +02:00
|
|
|
val ideaType: String by project
|
2024-02-07 15:04:10 +01:00
|
|
|
val ideaVersion: String by project
|
2024-02-07 15:18:54 +01:00
|
|
|
val javaVersion: String by project
|
2024-02-07 15:04:10 +01:00
|
|
|
|
|
|
|
repositories {
|
|
|
|
mavenCentral()
|
2024-05-09 14:48:56 +02:00
|
|
|
|
|
|
|
intellijPlatform {
|
|
|
|
defaultRepositories()
|
|
|
|
}
|
2024-02-07 15:04:10 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
dependencies {
|
|
|
|
testImplementation("org.junit.jupiter:junit-jupiter")
|
2024-02-08 08:16:16 +01:00
|
|
|
compileOnly("org.jetbrains.kotlin:kotlin-stdlib:$kotlinVersion")
|
2024-02-07 15:04:10 +01:00
|
|
|
testImplementation("org.jetbrains.kotlin:kotlin-test:$kotlinVersion")
|
|
|
|
testImplementation(testFixtures(project(":"))) // The root project
|
2024-07-26 17:09:59 +02:00
|
|
|
testImplementation("org.junit.vintage:junit-vintage-engine:5.10.3")
|
2024-05-09 14:48:56 +02:00
|
|
|
|
|
|
|
intellijPlatform {
|
|
|
|
create(ideaType, ideaVersion)
|
|
|
|
testFramework(TestFrameworkType.Platform)
|
|
|
|
testFramework(TestFrameworkType.JUnit5)
|
|
|
|
bundledPlugins("com.intellij.java", "org.jetbrains.plugins.yaml")
|
|
|
|
instrumentationTools()
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
intellijPlatform {
|
|
|
|
buildSearchableOptions = false
|
2024-02-07 15:04:10 +01:00
|
|
|
}
|
|
|
|
|
2024-02-09 15:45:57 +01:00
|
|
|
tasks {
|
|
|
|
test {
|
|
|
|
useJUnitPlatform()
|
|
|
|
}
|
2024-02-07 15:04:10 +01:00
|
|
|
}
|
2024-02-07 15:18:54 +01:00
|
|
|
|
|
|
|
java {
|
|
|
|
toolchain {
|
|
|
|
languageVersion.set(JavaLanguageVersion.of(javaVersion))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
kotlin {
|
|
|
|
jvmToolchain {
|
|
|
|
languageVersion.set(JavaLanguageVersion.of(javaVersion))
|
|
|
|
}
|
|
|
|
}
|