Skip to content

Commit

Permalink
test: update compression wpt
Browse files Browse the repository at this point in the history
PR-URL: #55191
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
  • Loading branch information
RedYetiDev authored Oct 11, 2024
1 parent d75bd2a commit 9ba3391
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion test/fixtures/wpt/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ See [test/wpt](../../wpt/README.md) for information on how these tests are run.
Last update:

- common: https://github.com/web-platform-tests/wpt/tree/dbd648158d/common
- compression: https://github.com/web-platform-tests/wpt/tree/5aa50dd415/compression
- compression: https://github.com/web-platform-tests/wpt/tree/da8d6860b2/compression
- console: https://github.com/web-platform-tests/wpt/tree/767ae35464/console
- dom/abort: https://github.com/web-platform-tests/wpt/tree/0143fe244b/dom/abort
- dom/events: https://github.com/web-platform-tests/wpt/tree/0a811c5161/dom/events
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ const bufferSourceChunksForDeflate = [
},
{
name: 'Float16Array',
value: new Float16Array(new Uint8Array(compressedBytesWithDeflate).buffer)
value: () => new Float16Array(new Uint8Array(compressedBytesWithDeflate).buffer)
},
{
name: 'Float32Array',
Expand Down Expand Up @@ -100,7 +100,7 @@ const bufferSourceChunksForGzip = [
},
{
name: 'Float16Array',
value: new Float16Array(new Uint8Array(compressedBytesWithGzip).buffer)
value: () => new Float16Array(new Uint8Array(compressedBytesWithGzip).buffer)
},
{
name: 'Float32Array',
Expand Down Expand Up @@ -151,7 +151,7 @@ const bufferSourceChunksForDeflateRaw = [
},
{
name: 'Float16Array',
value: new Float16Array(new Uint8Array(compressedBytesWithDeflateRaw).buffer)
value: () => new Float16Array(new Uint8Array(compressedBytesWithDeflateRaw).buffer)
},
{
name: 'Float32Array',
Expand All @@ -172,7 +172,7 @@ for (const chunk of bufferSourceChunksForDeflate) {
const ds = new DecompressionStream('deflate');
const reader = ds.readable.getReader();
const writer = ds.writable.getWriter();
const writePromise = writer.write(chunk.value);
const writePromise = writer.write(typeof chunk.value === 'function' ? chunk.value() : chunk.value);
writer.close();
const { value } = await reader.read();
assert_array_equals(Array.from(value), deflateExpectedChunkValue, 'value should match');
Expand All @@ -184,7 +184,7 @@ for (const chunk of bufferSourceChunksForGzip) {
const ds = new DecompressionStream('gzip');
const reader = ds.readable.getReader();
const writer = ds.writable.getWriter();
const writePromise = writer.write(chunk.value);
const writePromise = writer.write(typeof chunk.value === 'function' ? chunk.value() : chunk.value);
writer.close();
const { value } = await reader.read();
assert_array_equals(Array.from(value), gzipExpectedChunkValue, 'value should match');
Expand All @@ -196,7 +196,7 @@ for (const chunk of bufferSourceChunksForDeflateRaw) {
const ds = new DecompressionStream('deflate-raw');
const reader = ds.readable.getReader();
const writer = ds.writable.getWriter();
const writePromise = writer.write(chunk.value);
const writePromise = writer.write(typeof chunk.value === 'function' ? chunk.value() : chunk.value);
writer.close();
const { value } = await reader.read();
assert_array_equals(Array.from(value), deflateRawExpectedChunkValue, 'value should match');
Expand Down
2 changes: 1 addition & 1 deletion test/fixtures/wpt/versions.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"path": "common"
},
"compression": {
"commit": "5aa50dd4151b5bc1d04d5505366c6e27df30af5b",
"commit": "da8d6860b22271d8ef4dc7894509692aaab9adf8",
"path": "compression"
},
"console": {
Expand Down

0 comments on commit 9ba3391

Please sign in to comment.