Commit dd820377 authored by Jérome Perrin's avatar Jérome Perrin

Zelenium: catch errors when dumping DOM

This can happen with cross origin document, when using open on another
domain. In that case selenium crashes and the test never finishes, this
allows selenium to finish and report the error.
parent 5a6b5e91
......@@ -553,7 +553,11 @@ objectExtend(HtmlTestCaseRow.prototype, {
)
return convertDocumentToDataUrl(doc);
}
aElement.href = recursiveConvertIframeToDataUrl(sel$('selenium_myiframe').contentWindow.document);
try {
aElement.href = recursiveConvertIframeToDataUrl(sel$('selenium_myiframe').contentWindow.document);
} catch (e) {
console.warn("Ignored error while dumping document");
}
this.trElement.cells[2].appendChild(aElement);
}
},
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment