Commit 9ef3909f authored by Hitoshi Yoshida's avatar Hitoshi Yoshida Committed by Commit Bot

Web Locks: Make 'signal' member non nullable in LockOptions

This CL makes 'signal' member in LockOption non nullable
to be spec conformant. [1]
It also drops a test that is inconsistent with this change.

[1] https://inexorabletash.github.io/web-locks/#idl-index


Bug: 855968
Change-Id: I4faf6582451347a05eeca34f02e25a43217d86cd
Reviewed-on: https://chromium-review.googlesource.com/1121953
Commit-Queue: Joshua Bell <jsbell@chromium.org>
Reviewed-by: default avatarJoshua Bell <jsbell@chromium.org>
Reviewed-by: default avatarKentaro Hara <haraken@chromium.org>
Cr-Commit-Position: refs/heads/master@{#572244}
parent 185e5edc
......@@ -25,14 +25,6 @@ promise_test(async t => {
res, {signal}, t.unreached_func('callback should not run')),
'Bindings should throw if the signal option is a not an AbortSignal');
}
// These cases should work:
for (const signal of [null, undefined]) {
assert_equals(
undefined,
await navigator.locks.request(res, {signal}, lock => {}),
'Bindings should accept a null-ish signal option');
}
}, 'The signal option must be an AbortSignal');
promise_test(async t => {
......
......@@ -9,5 +9,5 @@ dictionary LockOptions {
LockMode mode = "exclusive";
boolean ifAvailable = false;
boolean steal = false;
AbortSignal? signal;
AbortSignal signal;
};
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment