Repository navigation
Port Angular E2E test apps to span streaming #23811
Description
Port these E2E test applications to span streaming (5 apps).
angular-19 already has a streamed variant from #23548 and is the reference. The other five are byte-identical to each other apart from the app name, so one port replays across the rest.
Apps
- angular-17
- angular-18
- angular-20
- angular-21
- angular-22
What to do
For each app:
- Remove the
traceLifecycle: 'static'pin added in test(e2e): Disable span streaming in e2e test applications #22590 fromsrc/main.ts. Angular cannot readprocess.envin the browser bundle, so if a per-variant lifecycle is wanted, follow thefileReplacementsapproachangular-19uses. - Rewrite
tests/performance.test.tsandtests/errors.test.tsfrom transaction envelopes to span v2:waitForTransactionbecomeswaitForStreamedSpan/waitForStreamedSpansevent.transactionbecomesspan.namecontexts.trace.opbecomesgetSpanOp(span)plusspan.is_segmentcontexts.trace.data['x']becomesspan.attributes['x'], which has the shape{ value, type }transaction_info.sourcebecomes thesentry.segment.name.sourceattribute
- The TraceDirective, TraceClass and TraceMethod specs all assert on child spans, so they need
collectStreamedSpansrather than a single envelope.
Angular router spans lose their /users/123 name and become Router under streaming (#23547), so those assertions have to change. The pageload and navigation segment names survive, because ResolveEnd renames the root span to the parameterized route.
Reference app: angular-19 (streamed variant). Worked example: #23797.
Keep static trace lifecycle coverage
Before porting this group, duplicate angular-20 as-is into angular-20-static and leave that copy on the current transaction-based specs. That keeps the static trace lifecycle covered once the rest of the group moves to streaming.
The copy is verbatim; only the app name changes:
package.json->namestart-event-proxy.mjs->proxyServerName- every
waitForTransaction/waitForError/waitForSessioncall intests/
Keep traceLifecycle: 'static' in the copy's Sentry.init calls. The e2e matrix discovers apps by directory, so no CI config change is needed.
angular-19 already runs both lifecycles through sentryTest.variants (#23548), so this copy may be redundant for Angular; check that before adding it.
Activity
linear-code commentedon Sep 1, 2026
JS-3495
test(e2e): Port the angular-21 E2E app to span streaming (#23984)
test(e2e): Port the angular-17 E2E app to span streaming (#23981)
test(e2e): Port the angular-18 E2E app to span streaming (#23982)
test(e2e): Port the angular-20 E2E app to span streaming (#23983)
test(e2e): Port the angular-22 E2E app to span streaming (#23985)