From 45eaed232577e9b66d2f0a596eb018c79e098541 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Fri, 10 Jan 2025 09:47:52 +0100 Subject: [PATCH] chore: update WPT (#3991) Co-authored-by: Uzlopak <5059100+Uzlopak@users.noreply.github.com> --- test/fixtures/wpt/interfaces/WebCryptoAPI.idl | 117 +++++++++++------- ...l => command-and-commandfor.tentative.idl} | 0 .../wpt/interfaces/digital-credentials.idl | 4 +- .../wpt/interfaces/element-timing.idl | 2 +- test/fixtures/wpt/interfaces/speech-api.idl | 2 +- test/fixtures/wpt/interfaces/turtledove.idl | 2 + test/fixtures/wpt/interfaces/wai-aria.idl | 2 +- test/fixtures/wpt/interfaces/webauthn.idl | 6 +- .../service-worker/fetch-with-body.https.html | 44 +++++++ .../resources/fetch-with-body-worker.js | 4 + .../resources/fetch-with-body-worker.py | 4 + 11 files changed, 133 insertions(+), 54 deletions(-) rename test/fixtures/wpt/interfaces/{invokers.tentative.idl => command-and-commandfor.tentative.idl} (100%) create mode 100644 test/fixtures/wpt/service-workers/service-worker/fetch-with-body.https.html create mode 100644 test/fixtures/wpt/service-workers/service-worker/resources/fetch-with-body-worker.js create mode 100644 test/fixtures/wpt/service-workers/service-worker/resources/fetch-with-body-worker.py diff --git a/test/fixtures/wpt/interfaces/WebCryptoAPI.idl b/test/fixtures/wpt/interfaces/WebCryptoAPI.idl index ae85c1cfe46..ff7a89cd0d5 100644 --- a/test/fixtures/wpt/interfaces/WebCryptoAPI.idl +++ b/test/fixtures/wpt/interfaces/WebCryptoAPI.idl @@ -42,52 +42,77 @@ enum KeyFormat { "raw", "spki", "pkcs8", "jwk" }; [SecureContext,Exposed=(Window,Worker)] interface SubtleCrypto { - Promise encrypt(AlgorithmIdentifier algorithm, - CryptoKey key, - BufferSource data); - Promise decrypt(AlgorithmIdentifier algorithm, - CryptoKey key, - BufferSource data); - Promise sign(AlgorithmIdentifier algorithm, - CryptoKey key, - BufferSource data); - Promise verify(AlgorithmIdentifier algorithm, - CryptoKey key, - BufferSource signature, - BufferSource data); - Promise digest(AlgorithmIdentifier algorithm, - BufferSource data); - - Promise generateKey(AlgorithmIdentifier algorithm, - boolean extractable, - sequence keyUsages ); - Promise deriveKey(AlgorithmIdentifier algorithm, - CryptoKey baseKey, - AlgorithmIdentifier derivedKeyType, - boolean extractable, - sequence keyUsages ); - Promise deriveBits(AlgorithmIdentifier algorithm, - CryptoKey baseKey, - optional unsigned long? length = null); - - Promise importKey(KeyFormat format, - (BufferSource or JsonWebKey) keyData, - AlgorithmIdentifier algorithm, - boolean extractable, - sequence keyUsages ); - Promise exportKey(KeyFormat format, CryptoKey key); - - Promise wrapKey(KeyFormat format, - CryptoKey key, - CryptoKey wrappingKey, - AlgorithmIdentifier wrapAlgorithm); - Promise unwrapKey(KeyFormat format, - BufferSource wrappedKey, - CryptoKey unwrappingKey, - AlgorithmIdentifier unwrapAlgorithm, - AlgorithmIdentifier unwrappedKeyAlgorithm, - boolean extractable, - sequence keyUsages ); + Promise encrypt( + AlgorithmIdentifier algorithm, + CryptoKey key, + BufferSource data + ); + Promise decrypt( + AlgorithmIdentifier algorithm, + CryptoKey key, + BufferSource data + ); + Promise sign( + AlgorithmIdentifier algorithm, + CryptoKey key, + BufferSource data + ); + Promise verify( + AlgorithmIdentifier algorithm, + CryptoKey key, + BufferSource signature, + BufferSource data + ); + Promise digest( + AlgorithmIdentifier algorithm, + BufferSource data + ); + + Promise<(CryptoKey or CryptoKeyPair)> generateKey( + AlgorithmIdentifier algorithm, + boolean extractable, + sequence keyUsages + ); + Promise deriveKey( + AlgorithmIdentifier algorithm, + CryptoKey baseKey, + AlgorithmIdentifier derivedKeyType, + boolean extractable, + sequence keyUsages + ); + Promise deriveBits( + AlgorithmIdentifier algorithm, + CryptoKey baseKey, + optional unsigned long? length = null + ); + + Promise importKey( + KeyFormat format, + (BufferSource or JsonWebKey) keyData, + AlgorithmIdentifier algorithm, + boolean extractable, + sequence keyUsages + ); + Promise<(ArrayBuffer or JsonWebKey)> exportKey( + KeyFormat format, + CryptoKey key + ); + + Promise wrapKey( + KeyFormat format, + CryptoKey key, + CryptoKey wrappingKey, + AlgorithmIdentifier wrapAlgorithm + ); + Promise unwrapKey( + KeyFormat format, + BufferSource wrappedKey, + CryptoKey unwrappingKey, + AlgorithmIdentifier unwrapAlgorithm, + AlgorithmIdentifier unwrappedKeyAlgorithm, + boolean extractable, + sequence keyUsages + ); }; dictionary RsaOtherPrimesInfo { diff --git a/test/fixtures/wpt/interfaces/invokers.tentative.idl b/test/fixtures/wpt/interfaces/command-and-commandfor.tentative.idl similarity index 100% rename from test/fixtures/wpt/interfaces/invokers.tentative.idl rename to test/fixtures/wpt/interfaces/command-and-commandfor.tentative.idl diff --git a/test/fixtures/wpt/interfaces/digital-credentials.idl b/test/fixtures/wpt/interfaces/digital-credentials.idl index 2207b25dd57..e20079efa14 100644 --- a/test/fixtures/wpt/interfaces/digital-credentials.idl +++ b/test/fixtures/wpt/interfaces/digital-credentials.idl @@ -8,10 +8,10 @@ partial dictionary CredentialRequestOptions { }; dictionary DigitalCredentialRequestOptions { - sequence requests; + sequence requests; }; -dictionary DigitalCredentialsRequest { +dictionary DigitalCredentialRequest { required DOMString protocol; required object data; }; diff --git a/test/fixtures/wpt/interfaces/element-timing.idl b/test/fixtures/wpt/interfaces/element-timing.idl index 586b5084bb0..ef73ca6c0f6 100644 --- a/test/fixtures/wpt/interfaces/element-timing.idl +++ b/test/fixtures/wpt/interfaces/element-timing.idl @@ -1,7 +1,7 @@ // GENERATED CONTENT - DO NOT EDIT // Content was automatically extracted by Reffy into webref // (https://github.com/w3c/webref) -// Source: Element Timing API (https://wicg.github.io/element-timing/) +// Source: Element Timing API (https://w3c.github.io/element-timing/) [Exposed=Window] interface PerformanceElementTiming : PerformanceEntry { diff --git a/test/fixtures/wpt/interfaces/speech-api.idl b/test/fixtures/wpt/interfaces/speech-api.idl index 74085481525..f3967b873ff 100644 --- a/test/fixtures/wpt/interfaces/speech-api.idl +++ b/test/fixtures/wpt/interfaces/speech-api.idl @@ -1,7 +1,7 @@ // GENERATED CONTENT - DO NOT EDIT // Content was automatically extracted by Reffy into webref // (https://github.com/w3c/webref) -// Source: Web Speech API (https://wicg.github.io/speech-api/) +// Source: Web Speech API (https://webaudio.github.io/web-speech-api/) [Exposed=Window] interface SpeechRecognition : EventTarget { diff --git a/test/fixtures/wpt/interfaces/turtledove.idl b/test/fixtures/wpt/interfaces/turtledove.idl index c416760d595..05072974ec9 100644 --- a/test/fixtures/wpt/interfaces/turtledove.idl +++ b/test/fixtures/wpt/interfaces/turtledove.idl @@ -41,6 +41,7 @@ dictionary GenerateBidInterestGroup { sequence trustedBiddingSignalsKeys; DOMString trustedBiddingSignalsSlotSizeMode = "none"; long maxTrustedBiddingSignalsURLLength; + USVString trustedBiddingSignalsCoordinator; any userBiddingSignals; sequence ads; sequence adComponents; @@ -104,6 +105,7 @@ dictionary AuctionAdConfig { USVString trustedScoringSignalsURL; long maxTrustedScoringSignalsURLLength; + USVString trustedScoringSignalsCoordinator; sequence interestGroupBuyers; Promise auctionSignals; Promise sellerSignals; diff --git a/test/fixtures/wpt/interfaces/wai-aria.idl b/test/fixtures/wpt/interfaces/wai-aria.idl index 78083f03f91..deebc5626e2 100644 --- a/test/fixtures/wpt/interfaces/wai-aria.idl +++ b/test/fixtures/wpt/interfaces/wai-aria.idl @@ -42,7 +42,7 @@ interface mixin ARIAMixin { [CEReactions] attribute DOMString? ariaPosInSet; [CEReactions] attribute DOMString? ariaPressed; [CEReactions] attribute DOMString? ariaReadOnly; - + [CEReactions] attribute DOMString? ariaRelevant; [CEReactions] attribute DOMString? ariaRequired; [CEReactions] attribute DOMString? ariaRoleDescription; [CEReactions] attribute DOMString? ariaRowCount; diff --git a/test/fixtures/wpt/interfaces/webauthn.idl b/test/fixtures/wpt/interfaces/webauthn.idl index 46e2418281e..a33c85e7bad 100644 --- a/test/fixtures/wpt/interfaces/webauthn.idl +++ b/test/fixtures/wpt/interfaces/webauthn.idl @@ -309,7 +309,7 @@ enum PublicKeyCredentialHint { }; partial dictionary AuthenticationExtensionsClientInputs { - USVString appid; + DOMString appid; }; partial dictionary AuthenticationExtensionsClientOutputs { @@ -317,7 +317,7 @@ partial dictionary AuthenticationExtensionsClientOutputs { }; partial dictionary AuthenticationExtensionsClientInputs { - USVString appidExclude; + DOMString appidExclude; }; partial dictionary AuthenticationExtensionsClientOutputs { @@ -343,7 +343,7 @@ dictionary AuthenticationExtensionsPRFValues { dictionary AuthenticationExtensionsPRFInputs { AuthenticationExtensionsPRFValues eval; - record evalByCredential; + record evalByCredential; }; partial dictionary AuthenticationExtensionsClientInputs { diff --git a/test/fixtures/wpt/service-workers/service-worker/fetch-with-body.https.html b/test/fixtures/wpt/service-workers/service-worker/fetch-with-body.https.html new file mode 100644 index 00000000000..21ded3f3272 --- /dev/null +++ b/test/fixtures/wpt/service-workers/service-worker/fetch-with-body.https.html @@ -0,0 +1,44 @@ + + + + + + + + diff --git a/test/fixtures/wpt/service-workers/service-worker/resources/fetch-with-body-worker.js b/test/fixtures/wpt/service-workers/service-worker/resources/fetch-with-body-worker.js new file mode 100644 index 00000000000..bef899c1b00 --- /dev/null +++ b/test/fixtures/wpt/service-workers/service-worker/resources/fetch-with-body-worker.js @@ -0,0 +1,4 @@ +self.addEventListener("fetch", (event) => { + event.request.body; + event.respondWith(fetch(event.request)); +}); diff --git a/test/fixtures/wpt/service-workers/service-worker/resources/fetch-with-body-worker.py b/test/fixtures/wpt/service-workers/service-worker/resources/fetch-with-body-worker.py new file mode 100644 index 00000000000..c5eeba0d67c --- /dev/null +++ b/test/fixtures/wpt/service-workers/service-worker/resources/fetch-with-body-worker.py @@ -0,0 +1,4 @@ +def main(request, response): + if len(request.body): + return 200, [], u"BODY" + return 400, [], u"NO BODY"