mirror of
https://github.com/denoland/deno.git
synced 2025-09-28 21:24:48 +00:00
fix: fix various global objects constructor length (#8373)
This commit changes various Web APIs constructors to match their signature in the browser.
This commit is contained in:
parent
3a0ebff641
commit
3d65e57d7c
8 changed files with 30 additions and 12 deletions
|
@ -118,6 +118,11 @@ function abortSignalHandlerLocation() {
|
|||
const abortHandler = Object.getOwnPropertyDescriptor(signal, "onabort");
|
||||
assertEquals(abortHandler, undefined);
|
||||
}
|
||||
function abortSignalLength() {
|
||||
const controller = new AbortController();
|
||||
const { signal } = controller;
|
||||
assertEquals(signal.constructor.length, 0);
|
||||
}
|
||||
function main() {
|
||||
basicAbortController();
|
||||
signalCallsOnabort();
|
||||
|
@ -128,6 +133,7 @@ function main() {
|
|||
abortSignalEventOrder();
|
||||
abortSignalEventOrderComplex();
|
||||
abortSignalHandlerLocation();
|
||||
abortSignalLength();
|
||||
}
|
||||
|
||||
main();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue