Roll src/third_party/WebKit d9c6159:8139f33 (svn 201974:201975)
[chromium-blink-merge.git] / chrome / test / data / notifications / notification-double-close.html
blob45ae47bf7b2d3831b447b0d509d9c7be5e1a1f27
1 <!doctype html>
2 <html>
3 <head>
4 <title>Verifies that double-closing a notification doesn't crash.</title>
5 <meta charset="utf-8">
6 </head>
7 <body>
8 <script>
9 function createNotification(iconUrl, title, text, tag) {
10 var notification = new Notification(title, {
11 icon: iconUrl,
12 body: text,
13 tag: tag
14 });
16 notification.onshow = function() {
17 window.domAutomationController.send("0"); // success
20 notification.onerror = function() {
21 window.domAutomationController.send("-1"); // failure
24 notification.onclose = function() {
25 notification.close();
28 </script>
29 </body>
30 </html>