[Gradle, JS] Remove redundant test
This commit is contained in:
committed by
TeamCityServer
parent
1cc5a9493c
commit
6219eb24c0
-27
@@ -831,33 +831,6 @@ abstract class AbstractKotlin2JsGradlePluginIT(val irBackend: Boolean) : BaseGra
|
||||
}
|
||||
}
|
||||
|
||||
@Test
|
||||
fun testUpdatingPackageJsonOnDependenciesClash() = with(Project("kotlin-js-dependencies-clash")) {
|
||||
setupWorkingDir()
|
||||
gradleBuildScript().modify(::transformBuildScriptWithPluginsDsl)
|
||||
|
||||
fun assertFileVersion(
|
||||
packageJson: PackageJson,
|
||||
dependency: String
|
||||
) {
|
||||
val version = packageJson.dependencies[dependency]!!
|
||||
assertTrue("${packageJson.name} must have $dependency with file version, but $version found") {
|
||||
version.isFileVersion()
|
||||
}
|
||||
}
|
||||
|
||||
build("packageJson", "rootPackageJson", "kotlinNpmInstall") {
|
||||
assertSuccessful()
|
||||
|
||||
val basePackageJson = getSubprojectPackageJson("base")
|
||||
val libPackageJson = getSubprojectPackageJson("lib")
|
||||
|
||||
val dependency = "kotlinx-coroutines-core"
|
||||
assertFileVersion(basePackageJson, dependency)
|
||||
assertFileVersion(libPackageJson, dependency)
|
||||
}
|
||||
}
|
||||
|
||||
@Test
|
||||
fun testYarnResolution() = with(Project("kotlin-js-yarn-resolutions")) {
|
||||
setupWorkingDir()
|
||||
|
||||
-18
@@ -1,18 +0,0 @@
|
||||
import org.jetbrains.kotlin.gradle.plugin.KotlinJsCompilerType.BOTH as BOTH_TYPE
|
||||
|
||||
plugins {
|
||||
kotlin("js")
|
||||
}
|
||||
|
||||
dependencies {
|
||||
implementation(kotlin("stdlib-js"))
|
||||
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-core-js:1.3.5")
|
||||
}
|
||||
|
||||
kotlin {
|
||||
js {
|
||||
useCommonJs()
|
||||
nodejs {
|
||||
}
|
||||
}
|
||||
}
|
||||
-14
@@ -1,14 +0,0 @@
|
||||
/*
|
||||
* Copyright 2010-2019 JetBrains s.r.o. and Kotlin Programming Language contributors.
|
||||
* Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file.
|
||||
*/
|
||||
|
||||
package com.example
|
||||
|
||||
fun best(): Int {
|
||||
return 42
|
||||
}
|
||||
|
||||
fun simpleBest(): Int {
|
||||
return 73
|
||||
}
|
||||
-13
@@ -1,13 +0,0 @@
|
||||
plugins {
|
||||
kotlin("js").version("<pluginMarkerVersion>").apply(false)
|
||||
}
|
||||
|
||||
group = "com.example"
|
||||
version = "1.0"
|
||||
|
||||
allprojects {
|
||||
repositories {
|
||||
mavenLocal()
|
||||
mavenCentral()
|
||||
}
|
||||
}
|
||||
-17
@@ -1,17 +0,0 @@
|
||||
plugins {
|
||||
kotlin("js")
|
||||
}
|
||||
|
||||
dependencies {
|
||||
implementation(kotlin("stdlib-js"))
|
||||
implementation(project(":base"))
|
||||
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-core-js:1.3.7")
|
||||
}
|
||||
|
||||
kotlin {
|
||||
target {
|
||||
useCommonJs()
|
||||
nodejs {
|
||||
}
|
||||
}
|
||||
}
|
||||
-14
@@ -1,14 +0,0 @@
|
||||
/*
|
||||
* Copyright 2010-2019 JetBrains s.r.o. and Kotlin Programming Language contributors.
|
||||
* Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file.
|
||||
*/
|
||||
|
||||
package com.example
|
||||
|
||||
fun answer(): Int {
|
||||
return best()
|
||||
}
|
||||
|
||||
fun sheldon(): Int {
|
||||
return simpleBest()
|
||||
}
|
||||
-11
@@ -1,11 +0,0 @@
|
||||
pluginManagement {
|
||||
repositories {
|
||||
mavenLocal()
|
||||
gradlePluginPortal()
|
||||
}
|
||||
}
|
||||
|
||||
rootProject.name = "kotlin-js-dependencies-clash"
|
||||
|
||||
include("base")
|
||||
include("lib")
|
||||
+1
-1
@@ -5,7 +5,7 @@ pluginManagement {
|
||||
}
|
||||
}
|
||||
|
||||
rootProject.name = "kotlin-js-dependencies-clash"
|
||||
rootProject.name = "kotlin-js-yarn-resolutions"
|
||||
|
||||
include("base")
|
||||
include("lib")
|
||||
Reference in New Issue
Block a user