Bug 1256786 - [ESLint] Fix ESLint issues in devtools/client/webconsole/test/browser_console_error_source_click.js. r=linclark
authorMichael Kohler <mkohler@picobudget.com>
Tue, 03 May 2016 16:03:00 -0400
changeset 296370 63e0b3c43236e3f783aea80a6800875b066871a4
parent 296369 7740286bd255b48e52cbf322ec3249741422b1d1
child 296371 2a70b4b044c35494a1b2c0d8a51dadc10bade3bf
push id76311
push usercbook@mozilla.com
push dateFri, 06 May 2016 12:26:12 +0000
treeherdermozilla-inbound@84a3e5716801 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerslinclark
bugs1256786
milestone49.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1256786 - [ESLint] Fix ESLint issues in devtools/client/webconsole/test/browser_console_error_source_click.js. r=linclark
devtools/client/webconsole/test/browser_console_error_source_click.js
--- a/devtools/client/webconsole/test/browser_console_error_source_click.js
+++ b/devtools/client/webconsole/test/browser_console_error_source_click.js
@@ -24,17 +24,17 @@ function test() {
 
     // On e10s, the exception is triggered in child process
     // and is ignored by test harness
     if (!Services.appinfo.browserTabsRemoteAutostart) {
       expectUncaughtException();
     }
 
     info("generate exception and wait for the message");
-    ContentTask.spawn(gBrowser.selectedBrowser, {}, function*() {
+    ContentTask.spawn(gBrowser.selectedBrowser, {}, function* () {
       let button = content.document.querySelector("button");
       button.click();
     });
 
     waitForMessages({
       webconsole: hud,
       messages: [
         {
@@ -49,24 +49,27 @@ function test() {
         },
       ],
     }).then(onMessageFound);
   }
 
   function onMessageFound(results) {
     let viewSource = hud.viewSource;
     let viewSourceCalled = false;
-    hud.viewSourceInDebugger = () => viewSourceCalled = true;
+    hud.viewSourceInDebugger = () => {
+      viewSourceCalled = true;
+    };
 
     for (let result of results) {
       viewSourceCalled = false;
 
       let msg = [...results[0].matched][0];
       ok(msg, "message element found for: " + result.text);
-      let locationNode = msg.querySelector(".message > .message-location .frame-link-filename");
+      let selector = ".message > .message-location .frame-link-filename";
+      let locationNode = msg.querySelector(selector);
       ok(locationNode, "message location element found");
 
       EventUtils.synthesizeMouse(locationNode, 2, 2, {}, hud.iframeWindow);
 
       ok(viewSourceCalled, "view source opened");
     }
 
     hud.viewSourceInDebugger = viewSource;