1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
6 function hasPermission() {
7 chrome
.test
.assertEq("granted", // permission not allowed
8 Notification
.permission
);
11 function showTextNotification() {
12 var notification
= new Notification("Foo", {
13 body
: "This is a text notification."
15 notification
.onerror = function() {
16 chrome
.test
.fail("Failed to show notification.");
18 notification
.onshow = function() {
19 chrome
.test
.succeed();