@@ -130,7 +130,7 @@ for (const {
130
130
expect ( response . status ) . toBe ( 307 )
131
131
expect ( response . headers . get ( 'location' ) , 'added a location header' ) . toBeTypeOf ( 'string' )
132
132
expect (
133
- new URL ( response . headers . get ( 'location' ) as string ) . pathname ,
133
+ new URL ( response . headers . get ( 'location' ) as string , 'http://n' ) . pathname ,
134
134
'redirected to the correct path' ,
135
135
) . toEqual ( '/other' )
136
136
expect ( response . headers . get ( 'x-runtime' ) ) . toEqual ( expectedRuntime )
@@ -154,7 +154,7 @@ for (const {
154
154
expect ( response . status ) . toBe ( 307 )
155
155
expect ( response . headers . get ( 'location' ) , 'added a location header' ) . toBeTypeOf ( 'string' )
156
156
expect (
157
- new URL ( response . headers . get ( 'location' ) as string ) . pathname ,
157
+ new URL ( response . headers . get ( 'location' ) as string , 'http://n' ) . pathname ,
158
158
'redirected to the correct path' ,
159
159
) . toEqual ( '/other' )
160
160
expect ( response . headers . get ( 'x-header-from-redirect' ) , 'hello' ) . toBe ( 'hello' )
@@ -357,7 +357,7 @@ for (const {
357
357
expect ( response . status ) . toBe ( 307 )
358
358
expect ( response . headers . get ( 'location' ) , 'added a location header' ) . toBeTypeOf ( 'string' )
359
359
expect (
360
- new URL ( response . headers . get ( 'location' ) as string ) . pathname ,
360
+ new URL ( response . headers . get ( 'location' ) as string , 'http://n' ) . pathname ,
361
361
'redirected to the correct path' ,
362
362
) . toEqual ( '/other' )
363
363
expect ( response . headers . get ( 'x-header-from-redirect' ) , 'hello' ) . toBe ( 'hello' )
@@ -382,7 +382,7 @@ for (const {
382
382
expect ( response . status ) . toBe ( 307 )
383
383
expect ( response . headers . get ( 'location' ) , 'added a location header' ) . toBeTypeOf ( 'string' )
384
384
expect (
385
- new URL ( response . headers . get ( 'location' ) as string ) . pathname ,
385
+ new URL ( response . headers . get ( 'location' ) as string , 'http://n' ) . pathname ,
386
386
'redirected to the correct path' ,
387
387
) . toEqual ( '/other' )
388
388
expect ( response . headers . get ( 'x-header-from-redirect' ) , 'hello' ) . toBe ( 'hello' )
0 commit comments