summaryrefslogtreecommitdiffstats
path: root/testing/web-platform/tests/vibration/invalid-values.html
diff options
context:
space:
mode:
authorMoonchild <moonchild@palemoon.org>2020-11-20 09:47:03 +0000
committerMoonchild <moonchild@palemoon.org>2020-11-20 09:47:03 +0000
commit5165ed02285315cc0bed7977c7bac6d0a90ca43c (patch)
tree9b761a21eb924915e51c2d803208e6c01b505a45 /testing/web-platform/tests/vibration/invalid-values.html
parente1db27e19989db11fef70f439cf95821316535b3 (diff)
parentca9abcdf1702c37bf00048dab3f460b2252873a3 (diff)
downloadUXP-RELBASE_20201120.tar
UXP-RELBASE_20201120.tar.gz
UXP-RELBASE_20201120.tar.lz
UXP-RELBASE_20201120.tar.xz
UXP-RELBASE_20201120.zip
Merge branch 'redwood' into releaseRELBASE_20201124RELBASE_20201120RC_20201120
Diffstat (limited to 'testing/web-platform/tests/vibration/invalid-values.html')
-rw-r--r--testing/web-platform/tests/vibration/invalid-values.html79
1 files changed, 0 insertions, 79 deletions
diff --git a/testing/web-platform/tests/vibration/invalid-values.html b/testing/web-platform/tests/vibration/invalid-values.html
deleted file mode 100644
index a544ac23c..000000000
--- a/testing/web-platform/tests/vibration/invalid-values.html
+++ /dev/null
@@ -1,79 +0,0 @@
-<!DOCTYPE html>
-<meta charset='utf-8'>
-<title>Vibration API: vibrate(invalid)</title>
-<link rel='author' title='Intel' href='http://www.intel.com'>
-<link rel='help' href='http://dev.w3.org/2009/dap/vibration/#vibration-interface'>
-
-<h1>Description</h1>
-<p>
- This test checks the <code>vibrate()</code> method with invalid parameter,
- taking vendor prefixes into account.
-</p>
-<div id='log'></div>
-<script src='/resources/testharness.js'></script>
-<script src='/resources/testharnessreport.js'></script>
-<script src='../support/vendor-prefix.js' data-prefixed-objects='[{"ancestors":["navigator"], "name":"vibrate"}]'></script>
-<script>
- test(function() {
- assert_throws(new TypeError(), function() {
- navigator.vibrate();
- }, 'Argument is required, so was expecting a TypeError.');
- }, 'Missing pattern argument');
-
- test(function() {
- try {
- navigator.vibrate(undefined);
- } catch(e) {
- assert_unreached('error message: ' + e.message);
- }
- }, 'pattern of undefined resolves to []');
-
- test(function() {
- try {
- navigator.vibrate(null);
- } catch(e) {
- assert_unreached('error message: ' + e.message);
- }
- }, 'pattern of null resolves to []');
-
- test(function() {
- try {
- navigator.vibrate('one');
- } catch(e) {
- assert_unreached('error message: ' + e.message);
- }
- }, 'pattern of empty string resolves to [""]');
-
- test(function() {
- try {
- navigator.vibrate('one');
- } catch(e) {
- assert_unreached('error message: ' + e.message);
- }
- }, 'pattern of string resolves to ["one"]');
-
- test(function() {
- try {
- navigator.vibrate(new String('one'));
- } catch(e) {
- assert_unreached('error message: ' + e.message);
- }
- }, 'pattern of String instance resolves to ["one"]');
-
- test(function() {
- try {
- navigator.vibrate(NaN);
- } catch(e) {
- assert_unreached('error message: ' + e.message);
- }
- }, 'pattern of NaN resolves to [NaN]');
-
- test(function() {
- try {
- navigator.vibrate({});
- } catch(e) {
- assert_unreached('error message: ' + e.message);
- }
- }, 'pattern of {} resolves to [{}]');
-</script>
-