@@ -3,7 +3,6 @@ import { waitForTransaction } from '@sentry-internal/test-utils';
33
44test ( 'lazyRouteTimeout: Routes load within timeout window' , async ( { page } ) => {
55 const transactionPromise = waitForTransaction ( 'react-router-7-lazy-routes' , async transactionEvent => {
6- console . log ( '[WAIT] Transaction Event:' , JSON . stringify ( transactionEvent , null , 2 ) ) ;
76 return (
87 ! ! transactionEvent ?. transaction &&
98 transactionEvent . contexts ?. trace ?. op === 'navigation' &&
@@ -21,11 +20,6 @@ test('lazyRouteTimeout: Routes load within timeout window', async ({ page }) =>
2120
2221 const event = await transactionPromise ;
2322
24- console . log ( '[TEST] Routes load within timeout:' ) ;
25- console . log ( ' Transaction:' , event . transaction ) ;
26- console . log ( ' Source:' , event . contexts ?. trace ?. data ?. [ 'sentry.source' ] ) ;
27- console . log ( ' Finish reason:' , event . contexts ?. trace ?. data ?. [ 'sentry.idle_span_finish_reason' ] ) ;
28-
2923 // Should get full parameterized route
3024 expect ( event . transaction ) . toBe ( '/deep/level2/level3/:id' ) ;
3125 expect ( event . contexts ?. trace ?. data ?. [ 'sentry.source' ] ) . toBe ( 'route' ) ;
@@ -34,7 +28,6 @@ test('lazyRouteTimeout: Routes load within timeout window', async ({ page }) =>
3428
3529test ( 'lazyRouteTimeout: Infinity timeout always waits for routes' , async ( { page } ) => {
3630 const transactionPromise = waitForTransaction ( 'react-router-7-lazy-routes' , async transactionEvent => {
37- console . log ( '[WAIT] Transaction Event:' , JSON . stringify ( transactionEvent , null , 2 ) ) ;
3831 return (
3932 ! ! transactionEvent ?. transaction &&
4033 transactionEvent . contexts ?. trace ?. op === 'navigation' &&
@@ -51,10 +44,6 @@ test('lazyRouteTimeout: Infinity timeout always waits for routes', async ({ page
5144
5245 const event = await transactionPromise ;
5346
54- console . log ( '[TEST] Infinity timeout:' ) ;
55- console . log ( ' Transaction:' , event . transaction ) ;
56- console . log ( ' Source:' , event . contexts ?. trace ?. data ?. [ 'sentry.source' ] ) ;
57-
5847 // Should wait indefinitely and get full route
5948 expect ( event . transaction ) . toBe ( '/deep/level2/level3/:id' ) ;
6049 expect ( event . contexts ?. trace ?. data ?. [ 'sentry.source' ] ) . toBe ( 'route' ) ;
@@ -63,7 +52,6 @@ test('lazyRouteTimeout: Infinity timeout always waits for routes', async ({ page
6352
6453test ( 'idleTimeout: Captures all activity with increased timeout' , async ( { page } ) => {
6554 const transactionPromise = waitForTransaction ( 'react-router-7-lazy-routes' , async transactionEvent => {
66- console . log ( '[WAIT] Transaction Event:' , JSON . stringify ( transactionEvent , null , 2 ) ) ;
6755 return (
6856 ! ! transactionEvent ?. transaction &&
6957 transactionEvent . contexts ?. trace ?. op === 'navigation' &&
@@ -80,10 +68,6 @@ test('idleTimeout: Captures all activity with increased timeout', async ({ page
8068
8169 const event = await transactionPromise ;
8270
83- console . log ( '[TEST] Increased idleTimeout:' ) ;
84- console . log ( ' Transaction:' , event . transaction ) ;
85- console . log ( ' Duration:' , event . timestamp ! - event . start_timestamp ) ;
86-
8771 expect ( event . transaction ) . toBe ( '/deep/level2/level3/:id' ) ;
8872 expect ( event . contexts ?. trace ?. data ?. [ 'sentry.source' ] ) . toBe ( 'route' ) ;
8973 expect ( event . contexts ?. trace ?. data ?. [ 'sentry.idle_span_finish_reason' ] ) . toBe ( 'idleTimeout' ) ;
@@ -96,7 +80,6 @@ test('idleTimeout: Captures all activity with increased timeout', async ({ page
9680
9781test ( 'idleTimeout: Finishes prematurely with low timeout' , async ( { page } ) => {
9882 const transactionPromise = waitForTransaction ( 'react-router-7-lazy-routes' , async transactionEvent => {
99- console . log ( '[WAIT] Transaction Event:' , JSON . stringify ( transactionEvent , null , 2 ) ) ;
10083 return (
10184 ! ! transactionEvent ?. transaction &&
10285 transactionEvent . contexts ?. trace ?. op === 'navigation' &&
@@ -114,10 +97,6 @@ test('idleTimeout: Finishes prematurely with low timeout', async ({ page }) => {
11497
11598 const event = await transactionPromise ;
11699
117- console . log ( '[TEST] Low idleTimeout:' ) ;
118- console . log ( ' Transaction:' , event . transaction ) ;
119- console . log ( ' Duration:' , event . timestamp ! - event . start_timestamp ) ;
120-
121100 expect ( event . contexts ?. trace ?. data ?. [ 'sentry.idle_span_finish_reason' ] ) . toBe ( 'idleTimeout' ) ;
122101 expect ( event . transaction ) . toBe ( '/deep/level2/level3/:id' ) ;
123102 expect ( event . contexts ?. trace ?. data ?. [ 'sentry.source' ] ) . toBe ( 'route' ) ;
@@ -129,7 +108,6 @@ test('idleTimeout: Finishes prematurely with low timeout', async ({ page }) => {
129108
130109test ( 'idleTimeout: Pageload on deeply nested route' , async ( { page } ) => {
131110 const pageloadPromise = waitForTransaction ( 'react-router-7-lazy-routes' , async transactionEvent => {
132- console . log ( '[WAIT] Transaction Event:' , JSON . stringify ( transactionEvent , null , 2 ) ) ;
133111 return (
134112 ! ! transactionEvent ?. transaction &&
135113 transactionEvent . contexts ?. trace ?. op === 'pageload' &&
@@ -142,10 +120,6 @@ test('idleTimeout: Pageload on deeply nested route', async ({ page }) => {
142120
143121 const pageloadEvent = await pageloadPromise ;
144122
145- console . log ( '[TEST] Pageload on nested route:' ) ;
146- console . log ( ' Transaction:' , pageloadEvent . transaction ) ;
147- console . log ( ' Op:' , pageloadEvent . contexts ?. trace ?. op ) ;
148-
149123 expect ( pageloadEvent . transaction ) . toBe ( '/deep/level2/level3/:id' ) ;
150124 expect ( pageloadEvent . contexts ?. trace ?. data ?. [ 'sentry.source' ] ) . toBe ( 'route' ) ;
151125 expect ( pageloadEvent . contexts ?. trace ?. data ?. [ 'sentry.idle_span_finish_reason' ] ) . toBe ( 'idleTimeout' ) ;
0 commit comments