mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-29 15:52:07 +00:00
Bug 645268 - Try to fix randomly failing browser_webconsole_bug_595934_message_categories.js by properly capturing a variable value in a closure r=ehsan
This commit is contained in:
parent
22100730c3
commit
b12a86604c
@ -157,9 +157,10 @@ function testNext() {
|
||||
pos++;
|
||||
if (pos < TESTS.length) {
|
||||
if (TESTS[pos].onload) {
|
||||
let position = pos;
|
||||
browser.addEventListener("load", function(aEvent) {
|
||||
browser.removeEventListener(aEvent.type, arguments.callee, true);
|
||||
TESTS[pos].onload(aEvent);
|
||||
TESTS[position].onload(aEvent);
|
||||
}, true);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user