You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by an...@apache.org on 2016/10/25 08:08:34 UTC
cordova-coho git commit: Do not run tests on nightly builds
Repository: cordova-coho
Updated Branches:
refs/heads/master 6ad14f02d -> 748b10724
Do not run tests on nightly builds
Project: http://git-wip-us.apache.org/repos/asf/cordova-coho/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-coho/commit/748b1072
Tree: http://git-wip-us.apache.org/repos/asf/cordova-coho/tree/748b1072
Diff: http://git-wip-us.apache.org/repos/asf/cordova-coho/diff/748b1072
Branch: refs/heads/master
Commit: 748b107241e11292a06f1d8fefa6a3ca3283d450
Parents: 6ad14f0
Author: Vladimir Kotikov <ko...@gmail.com>
Authored: Tue Oct 25 11:07:13 2016 +0300
Committer: Vladimir Kotikov <ko...@gmail.com>
Committed: Tue Oct 25 11:07:13 2016 +0300
----------------------------------------------------------------------
src/nightly.js | 38 --------------------------------------
1 file changed, 38 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cordova-coho/blob/748b1072/src/nightly.js
----------------------------------------------------------------------
diff --git a/src/nightly.js b/src/nightly.js
index b8235e7..969a6aa 100644
--- a/src/nightly.js
+++ b/src/nightly.js
@@ -18,7 +18,6 @@ under the License.
*/
var apputil = require('./apputil');
-var executil = require('./executil');
var optimist = require('optimist');
var flagutil = require('./flagutil');
var repoutil = require('./repoutil');
@@ -29,7 +28,6 @@ var versionutil = require('./versionutil');
var gitutil = require('./gitutil');
var fs = require('fs');
var path = require('path');
-var npmlink = require('./npm-link');
var repoclone = require('./repo-clone');
module.exports = function*(argv) {
@@ -48,11 +46,6 @@ module.exports = function*(argv) {
desc: 'Don\'t actually publish to npm, just print what would be run.',
type:'boolean'
})
- .options('ignore-test-failures', {
- desc: 'Run the tests for cli and lib but don\'t fail the build if the tests are failing',
- type:'boolean',
- alias : 'ignoreTestFailures'
- })
.default({ r: DEFAULT_NIGHTLY_REPOS})
.argv;
@@ -64,17 +57,6 @@ module.exports = function*(argv) {
// Clone and update Repos
yield prepareRepos(argv.r);
- //npm link repos that should be linked
- yield npmlink();
-
- // npm install cli (and probablu other repos as a workaround for
- // NPM bug #10343 - https://github.com/npm/npm/issues/10343)
- var common = repoutil.getRepoById('common');
- var cli = repoutil.getRepoById('cli');
- yield repoutil.forEachRepo([common, cli], function*(repo) {
- yield executil.execHelper(executil.ARGS('npm install'), /*silent=*/true, false);
- });
-
var reposToBuild = flagutil.computeReposFromFlag(argv.r, { includeModules: true });
// Get updated nightly versions for all repos
/** @type {Object} A map of repo.id and a short SHA for every repo to build */
@@ -94,15 +76,6 @@ module.exports = function*(argv) {
versionutil.updatePlatformsConfig(VERSIONS);
}
- // Tests for platforms have some environment requirements (presence of build systems,
- // SDKs, etc.) which are impossible to satisfy in Jenkins environment, so we're
- // excluding platforms repos from testing
- var reposToTest = reposToBuild.filter(function (repo) {
- return !repoutil.isInRepoGroup(repo, 'platform');
- });
- // Run CLI + cordova-lib tests
- yield runTests(reposToTest, argv.ignoreTestFailures);
-
var options = {};
options.tag = 'nightly';
options.pretend = argv.pretend;
@@ -153,17 +126,6 @@ function updateRepoDependencies(repo, dependencies) {
fs.writeFileSync(packageJSONPath, JSON.stringify(packageJSON, null, 2) + '\n', 'utf8');
}
-function *runTests(repos, ignoreTestFailures) {
- yield repoutil.forEachRepo(repos, function *(repo) {
- try {
- yield executil.execHelper(executil.ARGS('npm test'), false, ignoreTestFailures);
- } catch (e) {
- if (!ignoreTestFailures) throw e;
- apputil.print('Skipping failing tests due to "ignore-test-failures flag"');
- }
- });
-}
-
/**
* Generates suffix for appending to nightly package version
* based on current date and SHA string.
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cordova.apache.org
For additional commands, e-mail: commits-help@cordova.apache.org