Bug 952998 - Follow-up to fix test and use document.documentURIObject rs=Unfocused

From 9609390ee1e49e13e8beaac9dc26eb2c9b37887b Mon Sep 17 00:00:00 2001
This commit is contained in:
Tim Taubert 2014-01-07 11:56:28 +01:00
Родитель e798ebf10c
Коммит bec8250798
2 изменённых файлов: 3 добавлений и 4 удалений

Просмотреть файл

@ -18,8 +18,7 @@ XPCOMUtils.defineLazyModuleGetter(this, "console",
// Returns the principal for a given |frame| contained in a given |docShell|.
function getPrincipalForFrame(docShell, frame) {
let ssm = Services.scriptSecurityManager;
let doc = frame && frame.document;
let uri = Services.io.newURI(doc.documentURI, null, null);
let uri = frame.document.documentURIObject;
return ssm.getDocShellCodebasePrincipal(uri, docShell);
}

Просмотреть файл

@ -59,12 +59,12 @@ add_task(function flush_on_duplicate() {
"sessionStorage data has been flushed when duplicating tabs");
yield promiseTabRestored(tab2);
let {storage} = JSON.parse(ss.getTabState(tab2));
gBrowser.removeTab(tab2)
let [{state: {storage}}] = JSON.parse(ss.getClosedTabData(window));
is(storage["http://example.com"].test, "on-duplicate",
"sessionStorage data has been flushed when duplicating tabs");
gBrowser.removeTab(tab);
gBrowser.removeTab(tab2);
});
/**