Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(5106)

Unified Diff: chrome/test/data/extensions/api_test/events/background.js

Issue 10829186: Tabs API is usable without tabs permission. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: ETU now SetString()'s for empty values Created 8 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/test/data/extensions/api_test/events/background.js
diff --git a/chrome/test/data/extensions/api_test/events/background.js b/chrome/test/data/extensions/api_test/events/background.js
index 4477c20424c96bdb43021950effa028c59b9b214..dee47d8d9f03ff472dbb0d9c76df91ce23dfb14c 100644
--- a/chrome/test/data/extensions/api_test/events/background.js
+++ b/chrome/test/data/extensions/api_test/events/background.js
@@ -8,15 +8,16 @@ chrome.test.runTests([
function attachAndDetachNoPermisssions() {
function dummy() {};
try {
- chrome.tabs.onUpdated.addListener(dummy);
+ chrome.management.onEnabled.addListener(dummy);
chrome.test.fail();
} catch (e) {
chrome.test.assertTrue(
e.message.search("You do not have permission") >= 0,
e.message);
}
- chrome.test.assertFalse(chrome.tabs.onUpdated.hasListeners());
- chrome.tabs.onUpdated.removeListener(dummy); // browser should not DCHECK
+ chrome.test.assertFalse(chrome.management.onEnabled.hasListeners());
+ // Browser should not DCHECK.
+ chrome.management.onEnabled.removeListener(dummy);
chrome.test.succeed();
},

Powered by Google App Engine
This is Rietveld 408576698