mirror of
https://github.com/servo/servo.git
synced 2025-08-16 19:05:33 +01:00
Update web-platform-tests to revision 4a5223502fa660ce03e470af6a61c8bc26c5a8ee
This commit is contained in:
parent
c5f7c9ccf3
commit
e891345f26
1328 changed files with 36632 additions and 20588 deletions
|
@ -130,4 +130,24 @@ usb_test(usb => {
|
|||
});
|
||||
});
|
||||
}, 'ondisconnect event is triggered by removing a device');
|
||||
|
||||
usb_test(() => {
|
||||
return getFakeDevice().then(({ device, fakeDevice }) => {
|
||||
navigator.usb.test.onrequestdevice = event => {
|
||||
event.respondWith(fakeDevice);
|
||||
}
|
||||
return callWithTrustedClick(() => {
|
||||
let first = navigator.usb.requestDevice({ filters: [] });
|
||||
let second = navigator.usb.requestDevice({ filters: [] });
|
||||
return Promise.all([
|
||||
first.then(chosenDevice => {
|
||||
assert_equals(chosenDevice, device);
|
||||
}),
|
||||
second.then(chosenDevice => {
|
||||
assert_equals(chosenDevice, device);
|
||||
})
|
||||
]);
|
||||
});
|
||||
});
|
||||
}, 'multiple requestDevice calls are allowed per user activation');
|
||||
</script>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue