@@ -36,7 +36,7 @@ for (const { AbortControllerImpl, controllerName } of controllers) {
3636 abortController . abort ( )
3737
3838 client . request ( { path : '/' , method : 'GET' , signal : abortController . signal } , ( err , response ) => {
39- p . ok ( err instanceof errors . RequestAbortedError )
39+ p . ok ( err instanceof errors . RequestAbortedError || err instanceof DOMException )
4040 } )
4141 } )
4242
@@ -73,7 +73,7 @@ for (const { AbortControllerImpl, controllerName } of controllers) {
7373 } )
7474
7575 client . request ( { path : '/' , method : 'GET' , signal : abortController . signal } , ( err , response ) => {
76- p . ok ( err instanceof errors . RequestAbortedError )
76+ p . ok ( err instanceof errors . RequestAbortedError || err instanceof DOMException )
7777 } )
7878
7979 abortController . abort ( )
@@ -98,7 +98,7 @@ for (const { AbortControllerImpl, controllerName } of controllers) {
9898 t . after ( client . destroy . bind ( client ) )
9999
100100 client . request ( { path : '/' , method : 'GET' , signal : abortController . signal } , ( err , response ) => {
101- p . ok ( err instanceof errors . RequestAbortedError )
101+ p . ok ( err instanceof errors . RequestAbortedError || err instanceof DOMException )
102102 } )
103103 } )
104104
@@ -122,7 +122,7 @@ for (const { AbortControllerImpl, controllerName } of controllers) {
122122 t . after ( client . destroy . bind ( client ) )
123123
124124 client . request ( { path : '/' , method : 'GET' , signal : abortController . signal } , ( err , response ) => {
125- p . ok ( err instanceof errors . RequestAbortedError )
125+ p . ok ( err instanceof errors . RequestAbortedError || err instanceof DOMException )
126126 } )
127127 } )
128128
@@ -149,7 +149,7 @@ for (const { AbortControllerImpl, controllerName } of controllers) {
149149 abortController . abort ( )
150150 } )
151151 response . body . on ( 'error' , err => {
152- p . ok ( err instanceof errors . RequestAbortedError )
152+ p . ok ( err instanceof errors . RequestAbortedError || err instanceof DOMException )
153153 } )
154154 } )
155155 } )
@@ -174,7 +174,7 @@ for (const { AbortControllerImpl, controllerName } of controllers) {
174174 t . after ( client . destroy . bind ( client ) )
175175
176176 client . request ( { path : '/' , method : 'POST' , body, signal : abortController . signal } , ( err , response ) => {
177- p . ok ( err instanceof errors . RequestAbortedError )
177+ p . ok ( err instanceof errors . RequestAbortedError || err instanceof DOMException )
178178 } )
179179 } )
180180 await p . completed
@@ -204,7 +204,7 @@ for (const { AbortControllerImpl, controllerName } of controllers) {
204204 t . after ( client . destroy . bind ( client ) )
205205
206206 client . request ( { path : '/' , method : 'POST' , body, signal : abortController . signal } , ( err , response ) => {
207- p . ok ( err instanceof errors . RequestAbortedError )
207+ p . ok ( err instanceof errors . RequestAbortedError || err instanceof DOMException )
208208 } )
209209 } )
210210 await p . completed
@@ -237,7 +237,7 @@ for (const { AbortControllerImpl, controllerName } of controllers) {
237237 abortController . abort ( )
238238 } )
239239 response . body . on ( 'error' , err => {
240- p . ok ( err instanceof errors . RequestAbortedError )
240+ p . ok ( err instanceof errors . RequestAbortedError || err instanceof DOMException )
241241 } )
242242 } )
243243 } )
0 commit comments