From 42a4a03285033c36828fef4aead2957a9387d2aa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fredrik=20Wollse=CC=81n?= Date: Fri, 2 Mar 2018 15:19:33 +0200 Subject: [PATCH] Minor tweaks while debugging the broken browserAction --- src/background.js | 2 +- src/manifest.json | 1 + test/utils.js | 3 ++- 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/background.js b/src/background.js index 287ee69..22c7c6f 100644 --- a/src/background.js +++ b/src/background.js @@ -5,7 +5,6 @@ class BrowserActionButtonChoiceFeature { /** * - set image, text, click handler (telemetry) - * - tell Legacy Addon to send */ constructor(variation) { console.log( @@ -29,6 +28,7 @@ class BrowserActionButtonChoiceFeature { * - change label */ handleButtonClick() { + console.log("handleButtonClick"); // note: doesn't persist across a session, unless you use localStorage or similar. this.timesClickedInSession += 1; console.log("got a click", this.timesClickedInSession); diff --git a/src/manifest.json b/src/manifest.json index 046e019..d3a92a5 100644 --- a/src/manifest.json +++ b/src/manifest.json @@ -35,6 +35,7 @@ }, "browser_action": { "browser_style": true, + "default_icon": "icons/isolatedcorndog.svg", "default_title": "button label" } } diff --git a/test/utils.js b/test/utils.js index d6653ab..8ba7cce 100644 --- a/test/utils.js +++ b/test/utils.js @@ -156,7 +156,8 @@ module.exports.installAddon = async(driver, fileLocation) => { path: fileLocation, temporary: true, }); - return executor.execute(installCmd); + await executor.execute(installCmd); + console.log(`Add-on at ${fileLocation} installed`); }; module.exports.uninstallAddon = async(driver, id) => {