mirror of
https://github.com/servo/servo.git
synced 2025-10-17 08:49:21 +01:00
Update web-platform-tests to revision fa5f0edd48aca7acfa7d35f1be31cb0dd65817c6
This commit is contained in:
parent
6659e9004d
commit
a4cebda3db
110 changed files with 1473 additions and 526 deletions
|
@ -1,20 +1,25 @@
|
|||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta charset="utf-8" />
|
||||
<title>WebShare Test: Share with an invalid URL</title>
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<script src="/resources/testdriver-vendor.js"></script>
|
||||
<script src="/resources/testdriver.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
<script>
|
||||
promise_test(t => {
|
||||
// URL is invalid in that the URL Parser returns failure (port is too
|
||||
// large).
|
||||
const url = 'http://example.com:65536';
|
||||
return promise_rejects_js(
|
||||
t, TypeError, navigator.share({url}));
|
||||
}, 'share with an invalid URL');
|
||||
promise_test(async t => {
|
||||
const url = "http://example.com:65536";
|
||||
await test_driver.bless(
|
||||
"web share",
|
||||
() => {
|
||||
return promise_rejects_js(t, TypeError, navigator.share({ url }));
|
||||
},
|
||||
"share with an invalid URL"
|
||||
);
|
||||
}, "share() rejects when URL is invalid");
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue