Currently viewSourceInDebugger() only waits for a source to be shown if it is
not the selected one. If the requested source is selected by default, it might
already be selected when the isLoading check is made. However, the actual
source text might still be loading since it is loaded asynchronously.
In this case the method does not wait for the source to be shown meaning the
method resolves before the source is ready in the debugger. This causes
browser_toolbox_view_source_01.js to fail intermittently with wrong
line number since it looks at the focused line BEFORE the source text has
loaded and the correct line is selected.
This changeset modifies the behavior of viewSourceInDebugger() to also wait for
source shown event if the source is already selected but still loading.
MozReview-Commit-ID: JvxjJ5Yt19a
--HG--
extra : rebase_source : d4ed2e02bb8bfd734e23600e06accf3e34be16cc
For simple rules like function spacing, we can auto-fix these across the code
base so they are followed in a consistent way.
To generate this patch, I ran:
./mach eslint devtools --no-ignore --fix
After this, I reverted any changes to third party files that we really do want
to ignore.
MozReview-Commit-ID: 6Q8BApkAW20