From e5ebd31436fa9ba4264d0c14795045d46eb5bf58 Mon Sep 17 00:00:00 2001 From: James M Snell Date: Wed, 10 Mar 2021 08:27:07 -0800 Subject: [PATCH] Add test for proposed AbortSignal.abort() Proposed new API addition. Refs: https://github.com/whatwg/dom/pull/960 --- dom/abort/event.any.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/dom/abort/event.any.js b/dom/abort/event.any.js index a67e6f400fcf1d..2589ba1ce45091 100644 --- a/dom/abort/event.any.js +++ b/dom/abort/event.any.js @@ -64,4 +64,9 @@ test(t => { controller.abort(); }, "the abort event should have the right properties"); +test(t => { + const signal = AbortSignal.abort(); + assert_true(signal.aborted); +}, "the AbortSignal.abort() static returns an already aborted signal"); + done();