mirror of
https://github.com/apache/cordova-plugin-file-transfer.git
synced 2026-04-28 00:02:49 +08:00
committed by
daserge
parent
f8b0f82dfa
commit
869eea41ec
@@ -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);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user