mirror of
https://github.com/servo/servo.git
synced 2025-08-12 08:55:32 +01:00
Update web-platform-tests to revision 5d33b4da92080b7658168bdb0fbdc3531bda1ddf
This commit is contained in:
parent
7010178691
commit
5b46b73c1b
139 changed files with 2001 additions and 261 deletions
|
@ -25,7 +25,7 @@ function waitSyntaxErrorPromise(t, scan_options) {
|
|||
return promise_rejects_dom(t, 'SyntaxError', reader.scan(scan_options));
|
||||
}
|
||||
|
||||
promise_test(async t => {
|
||||
nfc_test(async t => {
|
||||
const reader = new NDEFReader();
|
||||
const promises = [];
|
||||
invalid_signals.forEach(invalid_signal => {
|
||||
|
@ -35,12 +35,8 @@ promise_test(async t => {
|
|||
await Promise.all(promises);
|
||||
}, "Test that NDEFReader.scan rejects if signal is not an AbortSignal.");
|
||||
|
||||
promise_test(async t => {
|
||||
if (window.testRunner) {
|
||||
// Deny nfc permissions for Chromium testrunner.
|
||||
window.testRunner.setPermission('nfc', 'denied',
|
||||
location.origin, location.origin);
|
||||
}
|
||||
nfc_test(async t => {
|
||||
await test_driver.set_permission({ name: 'nfc' }, 'denied', false);
|
||||
const reader = new NDEFReader();
|
||||
await promise_rejects_dom(t, 'NotAllowedError', reader.scan());
|
||||
}, "NDEFReader.scan should fail if user permission is not granted.");
|
||||
|
@ -49,10 +45,6 @@ promise_test(async t => {
|
|||
// implementation for NFC Mojo interface.
|
||||
nfc_test(async (t, mockNFC) => {
|
||||
mockNFC.simulateClosedPipe();
|
||||
if (window.testRunner) {
|
||||
window.testRunner.setPermission('nfc', 'granted',
|
||||
location.origin, location.origin);
|
||||
}
|
||||
const reader = new NDEFReader();
|
||||
const readerWatcher = new EventWatcher(t, reader, ["reading", "error"]);
|
||||
const promise = readerWatcher.wait_for("error").then(event => {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue