Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 11 additions & 1 deletion digital-credentials/get.https.html
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,7 @@
}, "navigator.credentials.get() promise is rejected if abort controller is aborted after call to get() in cross-origin iframe.");

promise_test(async (t) => {
for (const mediation of ["silent", "optional", "conditional", "required"]) {
for (const mediation of ["silent", "optional", "required"]) {
const abortController = new AbortController();
const { signal } = abortController;
await test_driver.bless("user activation");
Expand All @@ -234,6 +234,16 @@
}
}, "Mediation is implicitly required and hence ignored. Request is aborted regardless.");

// https://www.w3.org/TR/credential-management-1/#algorithm-request step 8a
promise_test(async (t) => {
const options = makeGetOptions({ mediation: "conditional" });
await promise_rejects_js(
t,
TypeError,
navigator.credentials.get(options),
);
}, "navigator.credentials.get() rejects with TypeError when mediation is 'conditional' for digital credentials.");

promise_test(async t => {
const throwingValues = [
BigInt(123),
Expand Down
Loading