Skip to content
This repository was archived by the owner on Nov 10, 2026. It is now read-only.

coverage: cover synchronous IEnumerable<Type?> paths for ThatTypes assertions - #261

Merged
vbreuss merged 1 commit into
mainfrom
test/mutation-types
May 31, 2026
Merged

vbreuss merged 1 commit into
mainfrom
test/mutation-types

Conversation

@vbreuss

@vbreuss vbreuss commented May 31, 2026

Copy link
Copy Markdown
Member

Add array-based (IEnumerable<Type?>) tests so the synchronous IsMetBy overloads of the type-collection constraints are exercised. Filtered.Types implements IAsyncEnumerable on net8.0+, so the existing tests only hit the async constraint paths, leaving the sync equality/negation lambdas (AreEnums/AreNotEnums/AreInterfaces/AreNested/AreGeneric and the AreNot abstract/class/sealed/static/struct/record/recordstruct variants) without coverage.

Also cover the ThatTypes.ContainMethods null-element branch and sync factory, the ThatTypes.HaveNamespace sync factory, and a forceDirect failure for DoNotInheritFrom that renders the "directly " fragment.

…ions

Add array-based (IEnumerable<Type?>) tests so the synchronous IsMetBy
overloads of the type-collection constraints are exercised. Filtered.Types
implements IAsyncEnumerable on net8.0+, so the existing tests only hit the
async constraint paths, leaving the sync equality/negation lambdas
(AreEnums/AreNotEnums/AreInterfaces/AreNested/AreGeneric and the AreNot
abstract/class/sealed/static/struct/record/recordstruct variants) without
coverage.

Also cover the ThatTypes.ContainMethods null-element branch and sync
factory, the ThatTypes.HaveNamespace sync factory, and a forceDirect
failure for DoNotInheritFrom that renders the "directly " fragment.
@vbreuss vbreuss self-assigned this May 31, 2026
@vbreuss vbreuss added the coverage Additional tests for edge cases or improvement of test coverage label May 31, 2026
@sonarqubecloud

Copy link
Copy Markdown

@github-actions

Copy link
Copy Markdown

Test Results

    13 files  ±  0      13 suites  ±0   5m 14s ⏱️ +11s
 4 224 tests + 36   4 221 ✅ + 36   3 💤 ±0  0 ❌ ±0 
25 324 runs  +216  25 311 ✅ +216  13 💤 ±0  0 ❌ ±0 

Results for commit 2f8467a. ± Comparison against base commit 0091a86.

@vbreuss
vbreuss merged commit cd28347 into main May 31, 2026
11 checks passed
@vbreuss
vbreuss deleted the test/mutation-types branch May 31, 2026 13:28
@github-actions

Copy link
Copy Markdown

👽 Mutation Results

Mutation testing badge

aweXpect.Reflection

Details
File Score Killed Survived Timeout No Coverage Ignored Compile Errors Total Detected Total Undetected Total Mutants

The final mutation score is NaN%

Coverage Thresholds: high:80 low:60 break:0

@github-actions

Copy link
Copy Markdown

🚀 Benchmark Results

Details

BenchmarkDotNet v0.15.8, Linux Ubuntu 24.04.4 LTS (Noble Numbat)
AMD EPYC 7763 2.83GHz, 1 CPU, 4 logical and 2 physical cores
.NET SDK 10.0.300
[Host] : .NET 10.0.8 (10.0.8, 10.0.826.23019), X64 RyuJIT x86-64-v3
DefaultJob : .NET 10.0.8 (10.0.8, 10.0.826.23019), X64 RyuJIT x86-64-v3

Method Mean Error StdDev Gen0 Allocated
TypeIsNotStatic_aweXpect 221.4 ns 4.22 ns 4.86 ns 0.0386 648 B

@github-actions

Copy link
Copy Markdown

This is addressed in release v1.5.0.

@github-actions github-actions Bot added the state: released The issue is released label May 31, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

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.

1 participant