Build: Make mochaTest a VerificationTask to allow skipping it with flag

#KTI-1076
This commit is contained in:
Vyacheslav Gerasimov
2022-12-22 16:29:38 +01:00
parent 7348e34fd0
commit 719cdce609
+2 -1
View File
@@ -107,6 +107,7 @@ if (kotlinBuildProperties.isInJpsBuildIdeaSync) {
enum class OsName { WINDOWS, MAC, LINUX, UNKNOWN }
enum class OsArch { X86_32, X86_64, ARM64, UNKNOWN }
data class OsType(val name: OsName, val arch: OsArch)
abstract class MochaTestTask : NpmTask(), VerificationTask
val currentOsType = run {
val gradleOs = OperatingSystem.current()
@@ -431,7 +432,7 @@ val npmInstall by tasks.getting(NpmTask::class) {
dependsOn(prepareNpmTestData)
}
val mochaTest by task<NpmTask> {
val mochaTest by task<MochaTestTask> {
workingDir.set(buildDir)
val target = if (project.hasProperty("teamcity")) "runOnTeamcity" else "test"