Andrew Top | 61a8495 | 2019-04-30 15:07:33 -0700 | [diff] [blame] | 1 | <!DOCTYPE html> |
| 2 | <meta charset="utf-8"> |
| 3 | <title>Notification constructor (invalid)</title> |
| 4 | <link rel="author" title="Intel" href="http://www.intel.com/"> |
| 5 | <link rel="author" title="Xin Liu" href="mailto:xinx.liu@intel.com"> |
| 6 | <script src="/resources/testharness.js"></script> |
| 7 | <script src="/resources/testharnessreport.js"></script> |
| 8 | <script> |
| 9 | test(function() { |
| 10 | if (Notification.permission != "granted") { |
| 11 | this.force_timeout() |
| 12 | this.set_status(this.NOTRUN, "You must allow notifications for this" |
| 13 | + " origin before running this test.") |
| 14 | } |
| 15 | assert_throws(new TypeError(), function() { |
| 16 | new Notification() |
| 17 | }) |
| 18 | }, "Called the notification constructor with no arguments.") |
| 19 | </script> |