Skip to content

Commit eaf147e

Browse files
committed
test(browser): Fix flaky browser integration test
1 parent a4e888f commit eaf147e

1 file changed

Lines changed: 3 additions & 4 deletions

File tree

  • dev-packages/browser-integration-tests/suites/profiling/traceLifecycleMode_overlapping-spans

dev-packages/browser-integration-tests/suites/profiling/traceLifecycleMode_overlapping-spans/test.ts

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -39,16 +39,15 @@ sentryTest(
3939
}
4040

4141
const url = await getLocalTestUrl({ testDir: __dirname, responseHeaders: { 'Document-Policy': 'js-profiling' } });
42-
await page.goto(url);
4342

44-
const profileChunkEnvelopePromise = getMultipleSentryEnvelopeRequests<ProfileChunkEnvelope>(
43+
const profileChunkEnvelopes = await getMultipleSentryEnvelopeRequests<ProfileChunkEnvelope>(
4544
page,
4645
1,
47-
{ envelopeType: 'profile_chunk' },
46+
{ url, envelopeType: 'profile_chunk', timeout: 5000 },
4847
properFullEnvelopeRequestParser,
4948
);
5049

51-
const profileChunkEnvelopeItem = (await profileChunkEnvelopePromise)[0][1][0];
50+
const profileChunkEnvelopeItem = profileChunkEnvelopes[0][1][0];
5251
const envelopeItemHeader = profileChunkEnvelopeItem[0];
5352
const envelopeItemPayload = profileChunkEnvelopeItem[1];
5453

0 commit comments

Comments
 (0)