Skip to content
Permalink
Browse files
CB-7287 - Mark XMLHttpRequest.spec.4 and storage.spec.18 tests as pen…
…ding when on iOS and using cordova-plugin-wkwebview-engine (due to known issues).
  • Loading branch information
shazron committed Dec 2, 2015
1 parent 785abbf commit f4e116b8a81e2470809a0ffba437fe268aaeab93
Showing 2 changed files with 13 additions and 1 deletion.
@@ -21,7 +21,9 @@

exports.defineAutoTests = function () {
var isWp8 = cordova.platformId === "windowsphone";

var isIOS = (cordova.platformId === "ios");
var isIOSWKWebView = isIOS && (window.webkit && window.webkit.messageHandlers);

describe("XMLHttpRequest", function () {
var errorHandler = {
onError: function (done) {
@@ -105,6 +107,10 @@ exports.defineAutoTests = function () {
});

it("XMLHttpRequest.spec.4 should be able to load the parent folder page ../index.html", function (done) {
if (isIOSWKWebView) {
pending();
}

createXHR("../index.html", true, done, errorHandler.onError.bind(null, done));
});

@@ -22,6 +22,8 @@ exports.defineAutoTests = function () {

var isWindowsPhone = cordova.platformId == 'windowsphone';
var isWindows = (cordova.platformId === "windows") || (cordova.platformId === "windows8")
var isIOS = (cordova.platformId === "ios");
var isIOSWKWebView = isIOS && (window.webkit && window.webkit.messageHandlers);

describe("Session Storage", function () {
it("storage.spec.1 should exist", function () {
@@ -211,6 +213,10 @@ exports.defineAutoTests = function () {
if (!window.openDatabase) {
pending();
}

if (isIOSWKWebView) {
pending();
}

var db = openDatabase("Database", "1.0", "HTML5 Database API example", 5 * 1024 * 1024);
db.transaction(function (t) {

3 comments on commit f4e116b

@purplecabbage
Copy link
Contributor

@purplecabbage purplecabbage commented on f4e116b Dec 2, 2015

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This may simply be an issue with expanding '..' or with CSP allowing access to the parent folder.
Can you try this ?

var path =  window.location.href.split('#')[0].split('/');
path.pop();
path.pop();
path.push("index.html");
createXHR(path.join("/"), true, done, errorHandler.onError.bind(null, done));

The above should have been attached here: f4e116b#diff-0adeeccac9c692970a6a414476e508e7R110

@shazron
Copy link
Contributor Author

@shazron shazron commented on f4e116b Dec 3, 2015

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll check it out and let you know.

@shazron
Copy link
Contributor Author

@shazron shazron commented on f4e116b Dec 3, 2015

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No change. With CSP off, loading any sibling files, child files give the same Cross Origin error - only http urls are allowed

Please sign in to comment.