You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by da...@apache.org on 2015/10/16 14:56:56 UTC

cordova-plugin-file-transfer git commit: CB-9673 Fixed test spec.6 failure on iOS

Repository: cordova-plugin-file-transfer
Updated Branches:
  refs/heads/master f8b0f82df -> 869eea41e


CB-9673 Fixed test spec.6 failure on iOS

github: close #102


Project: http://git-wip-us.apache.org/repos/asf/cordova-plugin-file-transfer/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-plugin-file-transfer/commit/869eea41
Tree: http://git-wip-us.apache.org/repos/asf/cordova-plugin-file-transfer/tree/869eea41
Diff: http://git-wip-us.apache.org/repos/asf/cordova-plugin-file-transfer/diff/869eea41

Branch: refs/heads/master
Commit: 869eea41ec37853e9cc7e74371f52f46353af993
Parents: f8b0f82
Author: Alexander Sorokin <al...@akvelon.com>
Authored: Wed Sep 16 19:04:29 2015 +0300
Committer: daserge <v-...@microsoft.com>
Committed: Fri Oct 16 10:15:01 2015 +0300

----------------------------------------------------------------------
 tests/tests.js | 3 +++
 1 file changed, 3 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-plugin-file-transfer/blob/869eea41/tests/tests.js
----------------------------------------------------------------------
diff --git a/tests/tests.js b/tests/tests.js
index 94ac89e..958327f 100644
--- a/tests/tests.js
+++ b/tests/tests.js
@@ -45,6 +45,7 @@ exports.defineAutoTests = function () {
     // flags
     var isWindows = cordova.platformId === 'windows8' || cordova.platformId === 'windows';
     var isWP8 = cordova.platformId === 'windowsphone';
+    var isIOS = cordova.platformId === 'ios';
 
     var isBrowser = cordova.platformId === 'browser';
     var isIE = isBrowser && navigator.userAgent.indexOf('Trident') >= 0;
@@ -175,6 +176,8 @@ exports.defineAutoTests = function () {
                 // In IE, when lengthComputable === false, event.total somehow is equal to 2^64
                 if (isIE) {
                     expect(event.total).toBe(Math.pow(2, 64));
+                } else if (isIOS) {
+                    expect(event.total).toBe(-1);
                 } else {
                     expect(event.total).toBe(0);
                 }


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cordova.apache.org
For additional commands, e-mail: commits-help@cordova.apache.org