Allow tracing the full, possibly async execution of a given mochitest script line
Categories
(DevTools :: General, enhancement)
Tracking
(firefox126 fixed)
Tracking | Status | |
---|---|---|
firefox126 | --- | fixed |
People
(Reporter: ochameau, Assigned: ochameau)
References
Details
Attachments
(2 files, 1 obsolete file)
Bug 1721427 introduced DEBUG_STEP=true
or DEBUG_STEP=50
to trace all executions of a given mochitest script, and pause it for a given amount of time in ms when giving a number.
This feature helps easily spot where an async test is stuck within the test script.
Now it doesn't help understanding why the test is paused.
We could introduce another instruction in order to be able to trace all execution, including the possible async execution being initiated from a given test line.
Assignee | ||
Comment 1•8 months ago
|
||
This typically help go from shared global to DevTools module loader globals (DevtoolsLoader and BrowserLoaders).
Assignee | ||
Comment 2•8 months ago
|
||
The existing feature DEBUG_STEP will help understand that the test is stuck on line 49
DEBUG_STEP=true ./mach mochitest browser_target_command_detach.js
On [STEP] browser_target_command_detach.js @ 49:3 :: ↦ await secondTargetCommand.startListening();
And the new DEBUG_TRACE_LINE feature will help understand where the code is stuck, deeply nested into async code of DevTools.
DEBUG_TRACE_LINE=49 ./mach mochitest browser_target_command_detach.js
On [STEP] target-command.js @ 512:7 :: ↦ await this._onFirstTarget;
Updated•8 months ago
|
Updated•8 months ago
|
Assignee | ||
Comment 3•8 months ago
|
||
Updated•8 months ago
|
Comment 5•8 months ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/e432142f97da
https://hg.mozilla.org/mozilla-central/rev/3e88f5e01d26
Description
•