Index: chrome/test/data/extensions/api_test/notifications/has_not_permission/background.js |
diff --git a/chrome/test/data/extensions/api_test/notifications/has_not_permission/background.js b/chrome/test/data/extensions/api_test/notifications/has_not_permission/background.js |
index dd415018bac3f528dc9a2883366a881fa5fb6079..1a4ee94d7b10bae8ff4f260b0f5663b84ce19c64 100644 |
--- a/chrome/test/data/extensions/api_test/notifications/has_not_permission/background.js |
+++ b/chrome/test/data/extensions/api_test/notifications/has_not_permission/background.js |
@@ -8,10 +8,17 @@ chrome.test.runTests([ |
webkitNotifications.checkPermission()); |
chrome.test.succeed(); |
}, |
- function showNotification() { |
+ function showHTMLNotification() { |
+ // createHTMLNotification should not be exposed. |
+ if (window.webkitNotifications.createHTMLNotification) |
+ chrome.test.fail("createHTMLNotification is found."); |
+ else |
+ chrome.test.succeed(); |
+ }, |
+ function showTextNotification() { |
try { |
- window.webkitNotifications.createHTMLNotification( |
- chrome.extension.getURL("notification.html")).show(); |
+ window.webkitNotifications.createNotification( |
+ "", "Foo", "This is text notification.").show(); |
} catch (e) { |
chrome.test.assertTrue(e.message.indexOf("SECURITY_ERR") == 0); |
chrome.test.succeed(); |