You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by ti...@apache.org on 2013/04/15 20:52:30 UTC
[43/54] [abbrv] git commit: Messed up ios merge - added some stuff
back in and cleaned the ios tests up a bit
Messed up ios merge - added some stuff back in and cleaned the ios tests up a bit
Project: http://git-wip-us.apache.org/repos/asf/cordova-plugman/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-plugman/commit/e777979d
Tree: http://git-wip-us.apache.org/repos/asf/cordova-plugman/tree/e777979d
Diff: http://git-wip-us.apache.org/repos/asf/cordova-plugman/diff/e777979d
Branch: refs/heads/future
Commit: e777979d3eafe4cbe29c5337d789addef9caded6
Parents: 684788f
Author: Tim Kim <ti...@adobe.com>
Authored: Tue Apr 9 15:19:54 2013 -0700
Committer: Tim Kim <ti...@adobe.com>
Committed: Tue Apr 9 15:26:43 2013 -0700
----------------------------------------------------------------------
platforms/ios.js | 13 +++++++++++++
test/ios-config-xml-install.js | 9 +--------
2 files changed, 14 insertions(+), 8 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cordova-plugman/blob/e777979d/platforms/ios.js
----------------------------------------------------------------------
diff --git a/platforms/ios.js b/platforms/ios.js
index b533e14..dad76d4 100644
--- a/platforms/ios.js
+++ b/platforms/ios.js
@@ -37,6 +37,19 @@ exports.handlePlugin = function (action, project_dir, plugin_dir, plugin_et, var
variables = variables || {}
+ var platformTag = plugin_et.find('./platform[@name="ios"]');
+
+ if (!platformTag) {
+ // Either this plugin doesn't support this platform, or it's a JS-only plugin.
+ // Either way, return now.
+ return;
+ }
+
+ var sourceFiles = platformTag.findall('./source-file'),
+ headerFiles = platformTag.findall('./header-file'),
+ resourceFiles = platformTag.findall('./resource-file'),
+ frameworks = platformTag.findall('./framework');
+
// grab and parse pbxproj
// we don't want CordovaLib's xcode project
var project_files = glob.sync(path.join(project_dir, '*.xcodeproj', 'project.pbxproj'));
http://git-wip-us.apache.org/repos/asf/cordova-plugman/blob/e777979d/test/ios-config-xml-install.js
----------------------------------------------------------------------
diff --git a/test/ios-config-xml-install.js b/test/ios-config-xml-install.js
index 68ec169..2a65268 100644
--- a/test/ios-config-xml-install.js
+++ b/test/ios-config-xml-install.js
@@ -65,23 +65,16 @@ exports['should install webless plugin'] = function (test) {
var dummy_plugin_dir = path.join(test_dir, 'plugins', 'WeblessPlugin')
var dummy_xml_path = path.join(test_dir, 'plugins', 'WeblessPlugin', 'plugin.xml')
var dummy_plugin_et = new et.ElementTree(et.XML(fs.readFileSync(dummy_xml_path, 'utf-8')));
-
-// out var/folders/k5/p44x4yn122s_gk2s0p0c7rm00000gn/T/test_plugman/projects/ios/SampleApp/Plugins/
-
-// test project dir var/folders/k5/p44x4yn122s_gk2s0p0c7rm00000gn/T/test_plugman/projects/ios
ios.handlePlugin('install', test_project_dir, dummy_plugin_dir, dummy_plugin_et, { APP_ID: 12345 });
plugin_loader.handlePrepare(test_project_dir, pluginsPath, wwwPath, 'ios');
- var huh = path.join(test_project_dir, 'SampleApp');
- console.log(huh);
- console.log('contents ' + fs.readdirSync(huh));
-
test.done();
}
exports['should move the js file'] = function (test) {
// run the platform-specific function
+ var pluginsPath = path.join(test_dir, 'plugins');
var wwwPath = path.join(test_dir, 'projects', 'ios', 'www');
var jsPath = path.join(test_dir, 'projects', 'ios-config-xml', 'www', 'childbrowser.js');