Skip to content

Commit

Permalink
Moved versions of npm dependencies used during build to gradle.proper…
Browse files Browse the repository at this point in the history
…ties
  • Loading branch information
elizarov committed Mar 5, 2018
1 parent 5f5107e commit 6140ca3
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 565 deletions.
4 changes: 4 additions & 0 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,9 @@ bintray_version = 1.7.3
gradle_node_version = 1.2.0
node_version = 8.9.3
npm_version = 5.7.1
mocha_version = 4.1.0
mocha_headless_chrome_version = 1.8.2
mocha_teamcity_reporter_version = 2.2.2
source_map_suport_version = 0.5.3

kotlin.incremental.multiplatform=true
18 changes: 14 additions & 4 deletions gradle/test-mocha-js.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,12 @@ node {
// -- Testing with Mocha under Node

task installDependenciesMochaNode(type: NpmTask) {
args = ['install', 'mocha', 'source-map-support', '--no-save']
if (project.hasProperty("teamcity")) args += 'mocha-teamcity-reporter'
args = ['install',
"mocha@$mocha_version",
"source-map-support@$source_map_suport_version",
'--no-save']
if (project.hasProperty("teamcity")) args += [
"mocha-teamcity-reporter@$mocha_teamcity_reporter_version"]
}

task prepareMochaNode(dependsOn: [compileTestKotlin2Js, populateNodeModules, installDependenciesMochaNode])
Expand All @@ -43,8 +47,14 @@ test.dependsOn testMochaNode
// -- Testing with Mocha under headless Chrome

task installDependenciesMochaChrome(type: NpmTask) {
args = ['install', 'mocha-headless-chrome', "kotlin@$kotlin_version", "kotlin-test@$kotlin_version", '--no-save']
if (project.hasProperty("teamcity")) args += 'mocha-teamcity-reporter'
args = ['install',
"mocha@$mocha_version",
"mocha-headless-chrome@$mocha_headless_chrome_version",
"kotlin@$kotlin_version",
"kotlin-test@$kotlin_version",
'--no-save']
if (project.hasProperty("teamcity")) args += [
"mocha-teamcity-reporter@$mocha_teamcity_reporter_version"]
}

task prepareMochaChrome(dependsOn: [compileTestKotlin2Js, populateNodeModules, installDependenciesMochaChrome])
Expand Down
Loading

0 comments on commit 6140ca3

Please sign in to comment.