зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1570279 - Reenable accidentally disabled checks in test_objectgrips-17.js. r=ochameau
Differential Revision: https://phabricator.services.mozilla.com//D40022 --HG-- extra : histedit_source : 557166c573619cf669c717928acbe483f9430df8
This commit is contained in:
Родитель
518b15a876
Коммит
8e65f8c891
|
@ -925,15 +925,19 @@ async function setupTestFromUrl(url) {
|
|||
* @param Object options
|
||||
* Optional arguments to tweak test environment
|
||||
* - JSPrincipal principal
|
||||
* Principal to use for the debuggee.
|
||||
* Principal to use for the debuggee. Defaults to systemPrincipal.
|
||||
* - boolean doNotRunWorker
|
||||
* If true, do not run this tests in worker debugger context.
|
||||
* If true, do not run this tests in worker debugger context. Defaults to false.
|
||||
* - bool wantXrays
|
||||
* Whether the debuggee wants Xray vision with respect to same-origin objects
|
||||
* outside the sandbox. Defaults to true.
|
||||
*/
|
||||
function threadFrontTest(test, options = {}) {
|
||||
let { principal, doNotRunWorker } = options;
|
||||
if (!principal) {
|
||||
principal = systemPrincipal;
|
||||
}
|
||||
const {
|
||||
principal = systemPrincipal,
|
||||
doNotRunWorker = false,
|
||||
wantXrays = true,
|
||||
} = options;
|
||||
|
||||
async function runThreadFrontTestWithServer(server, test) {
|
||||
// Setup a server and connect a client to it.
|
||||
|
@ -942,7 +946,7 @@ function threadFrontTest(test, options = {}) {
|
|||
// Create a custom debuggee and register it to the server.
|
||||
// We are using a custom Sandbox as debuggee. Create a new zone because
|
||||
// debugger and debuggee must be in different compartments.
|
||||
const debuggee = Cu.Sandbox(principal, { freshZone: true });
|
||||
const debuggee = Cu.Sandbox(principal, { freshZone: true, wantXrays });
|
||||
const scriptName = "debuggee.js";
|
||||
debuggee.__name = scriptName;
|
||||
server.addTestGlobal(debuggee);
|
||||
|
|
|
@ -299,7 +299,7 @@ async function run_tests_in_principal(
|
|||
// Test objects created in a cross-origin null principal new global.
|
||||
await testPrincipal(options, null, debuggeeHasXrays);
|
||||
|
||||
if (debuggeePrincipal === null) {
|
||||
if (debuggeePrincipal.isNullPrincipal) {
|
||||
// Test objects created in a same-origin null principal new global.
|
||||
await testPrincipal(
|
||||
options,
|
||||
|
|
Загрузка…
Ссылка в новой задаче