Skip to content

Commit c9378bb

Browse files
Clarify intent of PreFlightIgnoresTransaction test (#4792)
1 parent 761e10f commit c9378bb

4 files changed

+3
-56
lines changed

test/Sentry.AspNetCore.Tests/WebIntegrationTests.PreFlightIgnoresTransaction.DotNet10_0.verified.txt

Lines changed: 0 additions & 14 deletions
This file was deleted.

test/Sentry.AspNetCore.Tests/WebIntegrationTests.PreFlightIgnoresTransaction.DotNet8_0.verified.txt

Lines changed: 0 additions & 24 deletions
This file was deleted.

test/Sentry.AspNetCore.Tests/WebIntegrationTests.PreFlightIgnoresTransaction.DotNet9_0.verified.txt

Lines changed: 0 additions & 14 deletions
This file was deleted.

test/Sentry.AspNetCore.Tests/WebIntegrationTests.verify.cs

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -134,10 +134,9 @@ public async Task PreFlightIgnoresTransaction()
134134
// dispose will ultimately trigger the background worker to flush
135135
server.Dispose();
136136

137-
await Verify(new { result, transport.Payloads })
138-
.IgnoreStandardSentryMembers()
139-
.ScrubAspMembers()
140-
.UniqueForTargetFrameworkAndVersion();
137+
// No transaction should be recorded for pre-flight/options requests
138+
// See: https://github.com/getsentry/sentry-dotnet/issues/1835#issuecomment-1239546099
139+
transport.Payloads.Any().Should().BeFalse();
141140
}
142141

143142
[ApiController]

0 commit comments

Comments
 (0)