Skip to content

coverage: reduce exclusion of tests for .NET Framework#483

Merged
vbreuss merged 1 commit intomainfrom
topic/improve-test-coverage-for-netframework
Feb 11, 2026
Merged

coverage: reduce exclusion of tests for .NET Framework#483
vbreuss merged 1 commit intomainfrom
topic/improve-test-coverage-for-netframework

Conversation

@vbreuss
Copy link
Copy Markdown
Member

@vbreuss vbreuss commented Feb 11, 2026

Reduces conditional compilation exclusions so more of the HTTP monitoring tests run under .NET Framework, while still skipping the specific body-content assertions that aren’t supported there.

Key Changes:

  • Removed #if !NETFRAMEWORK guards around entire monitoring tests so the tests execute on .NET Framework.
  • Re-scoped #if !NETFRAMEWORK to only wrap assertions that read/validate request/response content payloads.

@vbreuss vbreuss self-assigned this Feb 11, 2026
Copilot AI review requested due to automatic review settings February 11, 2026 14:01
@vbreuss vbreuss added the coverage Additional tests for edge cases or improvement of test coverage label Feb 11, 2026
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Reduces conditional compilation exclusions so more of the HTTP monitoring tests run under .NET Framework, while still skipping the specific body-content assertions that aren’t supported/consistent there.

Changes:

  • Removed #if !NETFRAMEWORK guards around entire monitoring tests so the tests execute on .NET Framework.
  • Re-scoped #if !NETFRAMEWORK to only wrap assertions that read/validate request/response content payloads.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.

File Description
Tests/Mockolate.Tests/Web/ItExtensionsTests.IsHttpRequestMessageTests.cs Runs monitoring test on .NET Framework; skips only the content-length assertion for NETFRAMEWORK.
Tests/Mockolate.Tests/Web/ItExtensionsTests.IsHttpContentTests.cs Runs monitoring test on .NET Framework; skips only the byte-length assertion for NETFRAMEWORK.
Tests/Mockolate.Tests/Web/ItExtensionsTests.IsHttpContentTests.WithStringTests.cs Runs monitoring test on .NET Framework; skips only the string-content assertion for NETFRAMEWORK.

@vbreuss vbreuss enabled auto-merge (squash) February 11, 2026 14:02
@vbreuss vbreuss force-pushed the topic/improve-test-coverage-for-netframework branch from 49b7797 to 9b0fafe Compare February 11, 2026 14:05
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Feb 11, 2026

🚀 Benchmark Results

Details

BenchmarkDotNet v0.15.8, Linux Ubuntu 24.04.3 LTS (Noble Numbat)
AMD EPYC 7763 3.09GHz, 1 CPU, 4 logical and 2 physical cores
.NET SDK 10.0.103
[Host] : .NET 10.0.3 (10.0.3, 10.0.326.7603), X64 RyuJIT x86-64-v3

Job=InProcess Toolchain=InProcessEmitToolchain IterationCount=15
LaunchCount=1 WarmupCount=10

Method Mean Error StdDev Gen0 Gen1 Allocated
Simple_Mockolate 1.503 μs 0.0233 μs 0.0218 μs 0.2270 - 3.73 KB
Simple_Moq 172.452 μs 1.1854 μs 0.9899 μs 0.4883 - 14.55 KB
Simple_NSubstitute 5.634 μs 0.0346 μs 0.0289 μs 0.5569 0.0076 9.14 KB
Simple_FakeItEasy 6.211 μs 0.0328 μs 0.0307 μs 0.4959 - 8.11 KB

@sonarqubecloud
Copy link
Copy Markdown

@github-actions
Copy link
Copy Markdown

Test Results

    21 files  ±0      21 suites  ±0   5m 44s ⏱️ -39s
 2 729 tests ±0   2 728 ✅ ±0  1 💤 ±0  0 ❌ ±0 
18 320 runs  +3  18 319 ✅ +3  1 💤 ±0  0 ❌ ±0 

Results for commit 9b0fafe. ± Comparison against base commit b092f2d.

@vbreuss vbreuss merged commit ea544ff into main Feb 11, 2026
12 checks passed
@vbreuss vbreuss deleted the topic/improve-test-coverage-for-netframework branch February 11, 2026 14:11
@github-actions
Copy link
Copy Markdown

This is addressed in release v1.5.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

coverage Additional tests for edge cases or improvement of test coverage state: released The issue is released

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants