cordova-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mmo...@apache.org
Subject spec commit: CB-7086 Automatically install plugin tests
Date Thu, 17 Jul 2014 17:33:55 GMT
Repository: cordova-mobile-spec
Updated Branches:
  refs/heads/master 8a591f9bb -> 09b044043


CB-7086 Automatically install plugin tests


Project: http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/commit/09b04404
Tree: http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/tree/09b04404
Diff: http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/diff/09b04404

Branch: refs/heads/master
Commit: 09b0440439a23561193fb74de55956d047b2bc58
Parents: 8a591f9
Author: Michal Mocny <mmocny@gmail.com>
Authored: Thu Jul 17 13:33:39 2014 -0400
Committer: Michal Mocny <mmocny@gmail.com>
Committed: Thu Jul 17 13:33:39 2014 -0400

----------------------------------------------------------------------
 createmobilespec/createmobilespec.js | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/blob/09b04404/createmobilespec/createmobilespec.js
----------------------------------------------------------------------
diff --git a/createmobilespec/createmobilespec.js b/createmobilespec/createmobilespec.js
index 244c300..d44716b 100755
--- a/createmobilespec/createmobilespec.js
+++ b/createmobilespec/createmobilespec.js
@@ -240,6 +240,22 @@ if (argv.plugman) {
     shelljs.popd();
 }
 
+////////////////////// install new-style test plugins
+
+if (argv.plugman) {
+  // TODO
+} else {
+    shelljs.pushd(cli_project_dir);
+    console.log("Adding plugin tests using CLI...");
+    shelljs.ls('plugins').forEach(function(plugin) {
+      var potential_tests_plugin_xml = path.join('plugins', plugin, 'tests', 'plugin.xml')
+      if (fs.existsSync(potential_tests_plugin_xml)) {
+        shelljs.exec(cli + " plugin add " + path.dirname(potential_tests_plugin_xml));
+      }
+    });
+    shelljs.popd();
+}
+
 ////////////////////// update js files for each platform from cordova-js
 
 if (argv.skipjs) {


Mime
View raw message