Bug 1561435 - Fix test failures for devtools/server/, r=standard8

# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D35893

--HG--
extra : source : 9238d499b425da9f71e9afa887b200841b73ca1a
extra : intermediate-source : aa4fc8c9ee0d199e5b78bc6827f677605f71e70f
This commit is contained in:
Victor Porof 2019-06-19 13:43:15 -07:00
parent d8903e9911
commit 66e8f7440d
3 changed files with 31 additions and 41 deletions

View File

@ -41,39 +41,34 @@ function test_black_box() {
gThreadClient.resume().then(test_black_box_breakpoint);
});
/* eslint-disable no-multi-spaces, no-undef */
/* eslint-disable no-undef */
// prettier-ignore
Cu.evalInSandbox(
"" +
function doStuff(k) {
// line 1
const arg = 15; // line 2 - Break here
k(arg); // line 3
}, // line 4
"" + function doStuff(k) { // line 1
const arg = 15; // line 2 - Break here
k(arg); // line 3
}, // line 4
gDebuggee,
"1.8",
BLACK_BOXED_URL,
1
);
// prettier-ignore
Cu.evalInSandbox(
"" +
function runTest() {
// line 1
doStuff(
// line 2
function(n) {
// line 3
debugger; // line 5
} // line 6
); // line 7
} + // line 8
"\n debugger;", // line 9
"" + function runTest() { // line 1
doStuff( // line 2
function(n) { // line 3
debugger; // line 5
} // line 6
); // line 7
} // line 8
+ "\n debugger;", // line 9
gDebuggee,
"1.8",
SOURCE_URL,
1
);
/* eslint-enable no-multi-spaces, no-undef */
/* eslint-enable no-undef */
}
function test_black_box_breakpoint() {

View File

@ -41,32 +41,27 @@ function test_black_box() {
});
/* eslint-disable no-multi-spaces, no-undef */
// prettier-ignore
Cu.evalInSandbox(
"" +
function doStuff(k) {
// line 1
debugger; // line 2 - Break here
k(100); // line 3
}, // line 4
"" + function doStuff(k) { // line 1
debugger; // line 2 - Break here
k(100); // line 3
}, // line 4
gDebuggee,
"1.8",
BLACK_BOXED_URL,
1
);
// prettier-ignore
Cu.evalInSandbox(
"" +
function runTest() {
// line 1
doStuff(
// line 2
function(n) {
// line 3
Math.abs(n); // line 4 - Break here
} // line 5
); // line 6
} + // line 7
"\n debugger;", // line 8
"" + function runTest() { // line 1
doStuff( // line 2
function(n) { // line 3
Math.abs(n); // line 4 - Break here
} // line 5
); // line 6
} // line 7
+ "\n debugger;", // line 8
gDebuggee,
"1.8",
SOURCE_URL,

View File

@ -118,7 +118,7 @@ async function testThrow(dbg) {
packet = await stepOut(threadClient);
deepEqual(
getPauseLocation(packet),
{ line: 24, column: 0 },
{ line: 23, column: 0 },
`stepOut location in doThrow`
);