-
Notifications
You must be signed in to change notification settings - Fork 29.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
test: update encoding web-platform tests
PR-URL: #48320 Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com> Reviewed-By: Filip Skokan <panva.ip@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
- Loading branch information
Showing
4 changed files
with
28 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
20 changes: 20 additions & 0 deletions
20
test/fixtures/wpt/encoding/streams/stringification-crash.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
<!DOCTYPE html> | ||
<html class="test-wait"> | ||
<script id="workerScript" type="text/worker"> | ||
// Blob will pass a huge Uint8Array object whose stringification will take long | ||
const encoder = new TextEncoderStream() | ||
const blob = new Blob([new ArrayBuffer(1338720)]) | ||
const writable = new WritableStream() | ||
blob.stream().pipeThrough(encoder).pipeTo(writable) | ||
// Wait a bit for the piping to start | ||
Promise.resolve().then(() => postMessage('started')); | ||
</script> | ||
<script> | ||
const worker = new Worker(URL.createObjectURL(new Blob([ | ||
document.getElementById("workerScript").textContent | ||
]))) | ||
worker.onmessage = () => { | ||
worker.terminate(); | ||
document.documentElement.classList.remove("test-wait"); | ||
}; | ||
</script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters