@@ -51,6 +51,7 @@ describe(`handleError`, () => {
5151 expect ( spy ) . toHaveBeenCalledWith ( new Error ( "lazy error!" ) , {
5252 location : expect . objectContaining ( { pathname : "/" } ) ,
5353 params : { } ,
54+ unstable_pattern : "/" ,
5455 } ) ;
5556 expect ( spy ) . toHaveBeenCalledTimes ( 1 ) ;
5657 expect ( getHtml ( container ) ) . toContain ( "Unexpected Application Error!" ) ;
@@ -81,6 +82,7 @@ describe(`handleError`, () => {
8182 expect ( spy ) . toHaveBeenCalledWith ( new Error ( "middleware error!" ) , {
8283 location : expect . objectContaining ( { pathname : "/" } ) ,
8384 params : { } ,
85+ unstable_pattern : "/" ,
8486 } ) ;
8587 expect ( spy ) . toHaveBeenCalledTimes ( 1 ) ;
8688 } ) ;
@@ -109,6 +111,7 @@ describe(`handleError`, () => {
109111 expect ( spy ) . toHaveBeenCalledWith ( new Error ( "loader error!" ) , {
110112 location : expect . objectContaining ( { pathname : "/" } ) ,
111113 params : { } ,
114+ unstable_pattern : "/" ,
112115 } ) ;
113116 expect ( spy ) . toHaveBeenCalledTimes ( 1 ) ;
114117 } ) ;
@@ -139,6 +142,7 @@ describe(`handleError`, () => {
139142 expect ( spy ) . toHaveBeenCalledWith ( new Error ( "lazy error!" ) , {
140143 location : expect . objectContaining ( { pathname : "/page" } ) ,
141144 params : { } ,
145+ unstable_pattern : "/page" ,
142146 } ) ;
143147 expect ( spy ) . toHaveBeenCalledTimes ( 1 ) ;
144148 let html = getHtml ( container ) ;
@@ -174,6 +178,7 @@ describe(`handleError`, () => {
174178 expect ( spy ) . toHaveBeenCalledWith ( new Error ( "middleware error!" ) , {
175179 location : expect . objectContaining ( { pathname : "/page" } ) ,
176180 params : { } ,
181+ unstable_pattern : "/page" ,
177182 } ) ;
178183 expect ( spy ) . toHaveBeenCalledTimes ( 1 ) ;
179184 expect ( getHtml ( container ) ) . toContain ( "Error" ) ;
@@ -205,6 +210,7 @@ describe(`handleError`, () => {
205210 expect ( spy ) . toHaveBeenCalledWith ( new Error ( "loader error!" ) , {
206211 location : expect . objectContaining ( { pathname : "/page" } ) ,
207212 params : { } ,
213+ unstable_pattern : "/page" ,
208214 } ) ;
209215 expect ( spy ) . toHaveBeenCalledTimes ( 1 ) ;
210216 expect ( getHtml ( container ) ) . toContain ( "Error" ) ;
@@ -241,6 +247,7 @@ describe(`handleError`, () => {
241247 expect ( spy ) . toHaveBeenCalledWith ( new Error ( "action error!" ) , {
242248 location : expect . objectContaining ( { pathname : "/page" } ) ,
243249 params : { } ,
250+ unstable_pattern : "/page" ,
244251 } ) ;
245252 expect ( spy ) . toHaveBeenCalledTimes ( 1 ) ;
246253 expect ( getHtml ( container ) ) . toContain ( "Error" ) ;
@@ -270,6 +277,7 @@ describe(`handleError`, () => {
270277 expect ( spy ) . toHaveBeenCalledWith ( new Error ( "loader error!" ) , {
271278 location : expect . objectContaining ( { pathname : "/" } ) ,
272279 params : { } ,
280+ unstable_pattern : "/" ,
273281 } ) ;
274282 expect ( spy ) . toHaveBeenCalledTimes ( 1 ) ;
275283 expect ( getHtml ( container ) ) . toContain ( "Error" ) ;
@@ -304,6 +312,7 @@ describe(`handleError`, () => {
304312 expect ( spy ) . toHaveBeenCalledWith ( new Error ( "action error!" ) , {
305313 location : expect . objectContaining ( { pathname : "/" } ) ,
306314 params : { } ,
315+ unstable_pattern : "/" ,
307316 } ) ;
308317 expect ( spy ) . toHaveBeenCalledTimes ( 1 ) ;
309318 expect ( getHtml ( container ) ) . toContain ( "Error" ) ;
@@ -334,6 +343,7 @@ describe(`handleError`, () => {
334343 expect ( spy ) . toHaveBeenCalledWith ( new Error ( "render error!" ) , {
335344 location : expect . objectContaining ( { pathname : "/page" } ) ,
336345 params : { } ,
346+ unstable_pattern : "/page" ,
337347 errorInfo : expect . objectContaining ( {
338348 componentStack : expect . any ( String ) ,
339349 } ) ,
@@ -379,6 +389,7 @@ describe(`handleError`, () => {
379389 expect ( spy ) . toHaveBeenCalledWith ( new Error ( "await error!" ) , {
380390 location : expect . objectContaining ( { pathname : "/page" } ) ,
381391 params : { } ,
392+ unstable_pattern : "/page" ,
382393 } ) ;
383394 expect ( spy ) . toHaveBeenCalledTimes ( 1 ) ;
384395 expect ( getHtml ( container ) ) . toContain ( "Await Error" ) ;
@@ -427,6 +438,7 @@ describe(`handleError`, () => {
427438 expect ( spy ) . toHaveBeenCalledWith ( new Error ( "await error!" ) , {
428439 location : expect . objectContaining ( { pathname : "/page" } ) ,
429440 params : { } ,
441+ unstable_pattern : "/page" ,
430442 errorInfo : expect . objectContaining ( {
431443 componentStack : expect . any ( String ) ,
432444 } ) ,
@@ -481,10 +493,12 @@ describe(`handleError`, () => {
481493 expect ( spy ) . toHaveBeenCalledWith ( new Error ( "await error!" ) , {
482494 location : expect . objectContaining ( { pathname : "/page" } ) ,
483495 params : { } ,
496+ unstable_pattern : "/page" ,
484497 } ) ;
485498 expect ( spy ) . toHaveBeenCalledWith ( new Error ( "errorElement error!" ) , {
486499 location : expect . objectContaining ( { pathname : "/page" } ) ,
487500 params : { } ,
501+ unstable_pattern : "/page" ,
488502 errorInfo : expect . objectContaining ( {
489503 componentStack : expect . any ( String ) ,
490504 } ) ,
@@ -534,6 +548,7 @@ describe(`handleError`, () => {
534548 expect ( spy ) . toHaveBeenCalledWith ( new Error ( "loader error!" ) , {
535549 location : expect . objectContaining ( { pathname : "/page" } ) ,
536550 params : { } ,
551+ unstable_pattern : "/page" ,
537552 } ) ;
538553 expect ( spy ) . toHaveBeenCalledTimes ( 1 ) ;
539554 expect ( getHtml ( container ) ) . toContain ( "Error" ) ;
@@ -584,6 +599,7 @@ describe(`handleError`, () => {
584599 expect ( spy ) . toHaveBeenCalledWith ( new Error ( "render error!" ) , {
585600 location : expect . objectContaining ( { pathname : "/page" } ) ,
586601 params : { } ,
602+ unstable_pattern : "/page" ,
587603 errorInfo : expect . objectContaining ( {
588604 componentStack : expect . any ( String ) ,
589605 } ) ,
0 commit comments