Bug 1752737 - [devtools] Wait for original.js to be available before assertion r=nchevobbe

Differential Revision: https://phabricator.services.mozilla.com/D137511
This commit is contained in:
Hubert Boma Manilla 2022-02-01 16:35:23 +00:00
Родитель 51f5424c3d
Коммит e2e48a7ee4
1 изменённых файлов: 4 добавлений и 3 удалений

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

@ -15,9 +15,9 @@ add_task(async function testBreakableLinesOverReloads() {
info("Assert breakable lines of the first original source file, original.js");
await waitForSource(dbg, "original.js");
// The length of original.js is longer than the test file
// because the sourcemap replaces the content or the original file
// because the sourcemap replaces the content of the original file
// and appends a few lines with a "WEBPACK FOOTER" comment
// All the appended line are empty lines or comments, so none of them are breakable.
// All the appended lines are empty lines or comments, so none of them are breakable.
await assertBreakableLines(dbg, "original.js", 13, [[1,3], [5,8]]);
info("Assert breakable lines of the simple first load of script.js");
@ -29,7 +29,7 @@ add_task(async function testBreakableLinesOverReloads() {
info("Wait for script.js to be ready");
await waitForSelectedSource(dbg, "script.js");
info("Assert breakable lines of the more complex second load of script.js");
await assertBreakableLines(dbg, "script.js", 23, [[2], [13,23]]);
@ -37,6 +37,7 @@ add_task(async function testBreakableLinesOverReloads() {
await assertBreakableLines(dbg, "index.html", 21, [[15], [17]]);
info("Assert breakable lines of the second orignal file");
await waitForSource(dbg, "original.js");
// See first assertion about original.js,
// the size of original.js doesn't match the size of the test file
await assertBreakableLines(dbg, "original.js", 18, [[1,3], [8,11], [13]]);