Skip to content

feat(serilog): support restrictedToMinimumLevel when configuring Seri…

333e6f1
Select commit
Loading
Failed to load commit list.
Open

feat(serilog): support restrictedToMinimumLevel when configuring Serilog in code #5181

feat(serilog): support restrictedToMinimumLevel when configuring Seri…
333e6f1
Select commit
Loading
Failed to load commit list.
@sentry/warden / warden: code-review completed May 4, 2026 in 26s

1 issue

code-review: Found 1 issue (1 medium)

Medium

Filter test has no assertions verifying filtering behavior - `test/Sentry.Serilog.Tests/SentrySerilogSinkExtensionsTests.cs:129-143`

Sentry_WithRestrictedToMinimumLevel_FiltersLogsBelow logs a Warning and an Error but never asserts that the Warning was filtered out by Serilog or that the Error was delivered to the sink. With InitializeSdk = false and no spy/mock sink capturing log events, the test will pass even if restrictedToMinimumLevel is completely ignored. As a result, the new pass-through level functionality is not actually covered by a behavioral test, only by a does-not-throw smoke test.


Duration: 25.4s · Tokens: 237.2k in / 3.4k out · Cost: $2.51

Annotations

Check warning on line 143 in test/Sentry.Serilog.Tests/SentrySerilogSinkExtensionsTests.cs

See this annotation in the file changed.

@sentry-warden sentry-warden / warden: code-review

Filter test has no assertions verifying filtering behavior

`Sentry_WithRestrictedToMinimumLevel_FiltersLogsBelow` logs a Warning and an Error but never asserts that the Warning was filtered out by Serilog or that the Error was delivered to the sink. With `InitializeSdk = false` and no spy/mock sink capturing log events, the test will pass even if `restrictedToMinimumLevel` is completely ignored. As a result, the new pass-through level functionality is not actually covered by a behavioral test, only by a does-not-throw smoke test.