From f05f92fa3f64e7d4dc8b91a14aa062eb3ca22fc7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Valentin=20Breu=C3=9F?= Date: Sat, 6 Jun 2026 04:41:19 +0200 Subject: [PATCH 1/6] feat!: remove `EntryAssembly`/`ExecutingAssembly` source methods `Assembly.GetExecutingAssembly()` is resolved inside the library (stack crawl mark), so `In.ExecutingAssembly()` always returned the aweXpect.Reflection assembly itself - never the caller's assembly. `Assembly.GetEntryAssembly()` returns the test host (or `null`) under test runners. Both made namespace-clarified architecture assertions silently pass on empty collections in their primary use case. Removes `In.EntryAssembly()`, `In.ExecutingAssembly()`, `Types.InEntryAssembly()`, `Types.InExecutingAssembly()` and the matching `InNamespaceResult` clarifiers. Use `In.AssemblyContaining()` / `Types.InAssemblyContaining()` instead, which resolve the assembly reliably from the type argument. --- README.md | 3 -- .../Collections/Filtered.Types.cs | 13 ------- Source/aweXpect.Reflection/In.cs | 12 ------ Source/aweXpect.Reflection/Types.cs | 12 ------ .../Expected/aweXpect.Reflection_net10.0.txt | 6 --- .../Expected/aweXpect.Reflection_net8.0.txt | 6 --- .../aweXpect.Reflection_netstandard2.0.txt | 6 --- Tests/aweXpect.Reflection.Tests/InTests.cs | 28 -------------- Tests/aweXpect.Reflection.Tests/TypesTests.cs | 38 ------------------- 9 files changed, 124 deletions(-) diff --git a/README.md b/README.md index 4d4d14b1..ff189c21 100644 --- a/README.md +++ b/README.md @@ -94,8 +94,6 @@ evaluated collection that you can navigate and filter further. | `In.AllLoadedAssemblies()` | all currently loaded assemblies (system assemblies [excluded](#assembly-exclusions)) | | `In.Assemblies(a1, a2, …)` / `In.Assemblies(collection)` | the given assemblies | | `In.AssemblyContaining()` / `In.AssemblyContaining(typeof(T))` | the assembly that declares `T` | -| `In.EntryAssembly()` | the entry assembly | -| `In.ExecutingAssembly()` | the executing assembly | | `In.Type()` / `In.Type(typeof(T))` | a single type | | `In.Types()` / `In.Types()` / `In.Types(t1, t2, …)` | the given types | | `In.Constructors(…)` / `In.Events(…)` / `In.Fields(…)` / `In.Methods(…)` / `In.Properties(…)` | the given members | @@ -111,7 +109,6 @@ point for architecture rules: | `Types.InAllLoadedAssemblies()` | all types in all currently loaded assemblies | | `Types.InAssemblies(a1, a2, …)` | all types in the given assemblies | | `Types.InAssemblyContaining()` / `…(typeof(T))` | all types in the assembly that declares `T` | -| `Types.InEntryAssembly()` / `Types.InExecutingAssembly()` | all types in the entry / executing assembly | `Types.InNamespace(…)` searches all loaded assemblies by default; chain one of the same `In*` methods directly after it to clarify the assembly source (it can only be specified once, before any further filters): diff --git a/Source/aweXpect.Reflection/Collections/Filtered.Types.cs b/Source/aweXpect.Reflection/Collections/Filtered.Types.cs index 0b3c5a89..ad68a6ea 100644 --- a/Source/aweXpect.Reflection/Collections/Filtered.Types.cs +++ b/Source/aweXpect.Reflection/Collections/Filtered.Types.cs @@ -529,19 +529,6 @@ public Types InAssemblyContaining() /// public Types InAssemblyContaining(Type type) => In.AssemblyContaining(type).Types().WithinNamespace(_namespace); - - /// - /// Clarifies that the types within the namespace are searched in the . - /// - public Types InEntryAssembly() - => In.EntryAssembly().Types().WithinNamespace(_namespace); - - /// - /// Clarifies that the types within the namespace are searched in the - /// . - /// - public Types InExecutingAssembly() - => In.ExecutingAssembly().Types().WithinNamespace(_namespace); } /// diff --git a/Source/aweXpect.Reflection/In.cs b/Source/aweXpect.Reflection/In.cs index a4914912..2e256b88 100644 --- a/Source/aweXpect.Reflection/In.cs +++ b/Source/aweXpect.Reflection/In.cs @@ -50,18 +50,6 @@ public static Filtered.Assemblies AssemblyContaining() public static Filtered.Assemblies AssemblyContaining(Type type) => new(type.Assembly, $"in assembly containing type {Formatter.Format(type)}"); - /// - /// Defines expectations on the . - /// - public static Filtered.Assemblies EntryAssembly() - => new(Assembly.GetEntryAssembly(), "in entry assembly"); - - /// - /// Defines expectations on the . - /// - public static Filtered.Assemblies ExecutingAssembly() - => new(Assembly.GetExecutingAssembly(), "in executing assembly"); - /// /// Defines expectations on the type . /// diff --git a/Source/aweXpect.Reflection/Types.cs b/Source/aweXpect.Reflection/Types.cs index c4631d41..4448fabd 100644 --- a/Source/aweXpect.Reflection/Types.cs +++ b/Source/aweXpect.Reflection/Types.cs @@ -40,18 +40,6 @@ public static Filtered.Types InAssemblyContaining() public static Filtered.Types InAssemblyContaining(Type type) => In.AssemblyContaining(type).Types(); - /// - /// Defines expectations on all types in the . - /// - public static Filtered.Types InEntryAssembly() - => In.EntryAssembly().Types(); - - /// - /// Defines expectations on all types in the . - /// - public static Filtered.Types InExecutingAssembly() - => In.ExecutingAssembly().Types(); - /// /// Defines expectations on all types within the (including sub-namespaces). /// diff --git a/Tests/aweXpect.Reflection.Api.Tests/Expected/aweXpect.Reflection_net10.0.txt b/Tests/aweXpect.Reflection.Api.Tests/Expected/aweXpect.Reflection_net10.0.txt index 99151c76..0fb6bc8d 100644 --- a/Tests/aweXpect.Reflection.Api.Tests/Expected/aweXpect.Reflection_net10.0.txt +++ b/Tests/aweXpect.Reflection.Api.Tests/Expected/aweXpect.Reflection_net10.0.txt @@ -324,9 +324,7 @@ namespace aweXpect.Reflection public static aweXpect.Reflection.Collections.Filtered.Assemblies AssemblyContaining(System.Type type) { } public static aweXpect.Reflection.Collections.Filtered.Assemblies AssemblyContaining() { } public static aweXpect.Reflection.Collections.Filtered.Constructors Constructors(System.Collections.Generic.IEnumerable constructors) { } - public static aweXpect.Reflection.Collections.Filtered.Assemblies EntryAssembly() { } public static aweXpect.Reflection.Collections.Filtered.Events Events(System.Collections.Generic.IEnumerable events) { } - public static aweXpect.Reflection.Collections.Filtered.Assemblies ExecutingAssembly() { } public static aweXpect.Reflection.Collections.Filtered.Fields Fields(System.Collections.Generic.IEnumerable fields) { } public static aweXpect.Reflection.Collections.Filtered.Methods Methods(System.Collections.Generic.IEnumerable methods) { } public static aweXpect.Reflection.Collections.Filtered.Properties Properties(System.Collections.Generic.IEnumerable properties) { } @@ -2036,8 +2034,6 @@ namespace aweXpect.Reflection public static aweXpect.Reflection.Collections.Filtered.Types InAssemblies(System.Collections.Generic.IEnumerable assemblies) { } public static aweXpect.Reflection.Collections.Filtered.Types InAssemblyContaining(System.Type type) { } public static aweXpect.Reflection.Collections.Filtered.Types InAssemblyContaining() { } - public static aweXpect.Reflection.Collections.Filtered.Types InEntryAssembly() { } - public static aweXpect.Reflection.Collections.Filtered.Types InExecutingAssembly() { } public static aweXpect.Reflection.Collections.Filtered.Types.InNamespaceResult InNamespace(string @namespace) { } } } @@ -2213,8 +2209,6 @@ namespace aweXpect.Reflection.Collections public aweXpect.Reflection.Collections.Filtered.Types InAssemblies(System.Collections.Generic.IEnumerable assemblies) { } public aweXpect.Reflection.Collections.Filtered.Types InAssemblyContaining(System.Type type) { } public aweXpect.Reflection.Collections.Filtered.Types InAssemblyContaining() { } - public aweXpect.Reflection.Collections.Filtered.Types InEntryAssembly() { } - public aweXpect.Reflection.Collections.Filtered.Types InExecutingAssembly() { } } public sealed class NamespaceDependencyFilterResult : aweXpect.Reflection.Collections.Filtered.Types { diff --git a/Tests/aweXpect.Reflection.Api.Tests/Expected/aweXpect.Reflection_net8.0.txt b/Tests/aweXpect.Reflection.Api.Tests/Expected/aweXpect.Reflection_net8.0.txt index 28c2442d..245bf366 100644 --- a/Tests/aweXpect.Reflection.Api.Tests/Expected/aweXpect.Reflection_net8.0.txt +++ b/Tests/aweXpect.Reflection.Api.Tests/Expected/aweXpect.Reflection_net8.0.txt @@ -324,9 +324,7 @@ namespace aweXpect.Reflection public static aweXpect.Reflection.Collections.Filtered.Assemblies AssemblyContaining(System.Type type) { } public static aweXpect.Reflection.Collections.Filtered.Assemblies AssemblyContaining() { } public static aweXpect.Reflection.Collections.Filtered.Constructors Constructors(System.Collections.Generic.IEnumerable constructors) { } - public static aweXpect.Reflection.Collections.Filtered.Assemblies EntryAssembly() { } public static aweXpect.Reflection.Collections.Filtered.Events Events(System.Collections.Generic.IEnumerable events) { } - public static aweXpect.Reflection.Collections.Filtered.Assemblies ExecutingAssembly() { } public static aweXpect.Reflection.Collections.Filtered.Fields Fields(System.Collections.Generic.IEnumerable fields) { } public static aweXpect.Reflection.Collections.Filtered.Methods Methods(System.Collections.Generic.IEnumerable methods) { } public static aweXpect.Reflection.Collections.Filtered.Properties Properties(System.Collections.Generic.IEnumerable properties) { } @@ -2036,8 +2034,6 @@ namespace aweXpect.Reflection public static aweXpect.Reflection.Collections.Filtered.Types InAssemblies(System.Collections.Generic.IEnumerable assemblies) { } public static aweXpect.Reflection.Collections.Filtered.Types InAssemblyContaining(System.Type type) { } public static aweXpect.Reflection.Collections.Filtered.Types InAssemblyContaining() { } - public static aweXpect.Reflection.Collections.Filtered.Types InEntryAssembly() { } - public static aweXpect.Reflection.Collections.Filtered.Types InExecutingAssembly() { } public static aweXpect.Reflection.Collections.Filtered.Types.InNamespaceResult InNamespace(string @namespace) { } } } @@ -2213,8 +2209,6 @@ namespace aweXpect.Reflection.Collections public aweXpect.Reflection.Collections.Filtered.Types InAssemblies(System.Collections.Generic.IEnumerable assemblies) { } public aweXpect.Reflection.Collections.Filtered.Types InAssemblyContaining(System.Type type) { } public aweXpect.Reflection.Collections.Filtered.Types InAssemblyContaining() { } - public aweXpect.Reflection.Collections.Filtered.Types InEntryAssembly() { } - public aweXpect.Reflection.Collections.Filtered.Types InExecutingAssembly() { } } public sealed class NamespaceDependencyFilterResult : aweXpect.Reflection.Collections.Filtered.Types { diff --git a/Tests/aweXpect.Reflection.Api.Tests/Expected/aweXpect.Reflection_netstandard2.0.txt b/Tests/aweXpect.Reflection.Api.Tests/Expected/aweXpect.Reflection_netstandard2.0.txt index 0126d718..617fb73a 100644 --- a/Tests/aweXpect.Reflection.Api.Tests/Expected/aweXpect.Reflection_netstandard2.0.txt +++ b/Tests/aweXpect.Reflection.Api.Tests/Expected/aweXpect.Reflection_netstandard2.0.txt @@ -324,9 +324,7 @@ namespace aweXpect.Reflection public static aweXpect.Reflection.Collections.Filtered.Assemblies AssemblyContaining(System.Type type) { } public static aweXpect.Reflection.Collections.Filtered.Assemblies AssemblyContaining() { } public static aweXpect.Reflection.Collections.Filtered.Constructors Constructors(System.Collections.Generic.IEnumerable constructors) { } - public static aweXpect.Reflection.Collections.Filtered.Assemblies EntryAssembly() { } public static aweXpect.Reflection.Collections.Filtered.Events Events(System.Collections.Generic.IEnumerable events) { } - public static aweXpect.Reflection.Collections.Filtered.Assemblies ExecutingAssembly() { } public static aweXpect.Reflection.Collections.Filtered.Fields Fields(System.Collections.Generic.IEnumerable fields) { } public static aweXpect.Reflection.Collections.Filtered.Methods Methods(System.Collections.Generic.IEnumerable methods) { } public static aweXpect.Reflection.Collections.Filtered.Properties Properties(System.Collections.Generic.IEnumerable properties) { } @@ -1672,8 +1670,6 @@ namespace aweXpect.Reflection public static aweXpect.Reflection.Collections.Filtered.Types InAssemblies(System.Collections.Generic.IEnumerable assemblies) { } public static aweXpect.Reflection.Collections.Filtered.Types InAssemblyContaining(System.Type type) { } public static aweXpect.Reflection.Collections.Filtered.Types InAssemblyContaining() { } - public static aweXpect.Reflection.Collections.Filtered.Types InEntryAssembly() { } - public static aweXpect.Reflection.Collections.Filtered.Types InExecutingAssembly() { } public static aweXpect.Reflection.Collections.Filtered.Types.InNamespaceResult InNamespace(string @namespace) { } } } @@ -1849,8 +1845,6 @@ namespace aweXpect.Reflection.Collections public aweXpect.Reflection.Collections.Filtered.Types InAssemblies(System.Collections.Generic.IEnumerable assemblies) { } public aweXpect.Reflection.Collections.Filtered.Types InAssemblyContaining(System.Type type) { } public aweXpect.Reflection.Collections.Filtered.Types InAssemblyContaining() { } - public aweXpect.Reflection.Collections.Filtered.Types InEntryAssembly() { } - public aweXpect.Reflection.Collections.Filtered.Types InExecutingAssembly() { } } public sealed class NamespaceDependencyFilterResult : aweXpect.Reflection.Collections.Filtered.Types { diff --git a/Tests/aweXpect.Reflection.Tests/InTests.cs b/Tests/aweXpect.Reflection.Tests/InTests.cs index 07f7e463..e3977ff0 100644 --- a/Tests/aweXpect.Reflection.Tests/InTests.cs +++ b/Tests/aweXpect.Reflection.Tests/InTests.cs @@ -84,22 +84,6 @@ public async Task Constructors_WithEnumerable_ShouldContainProvidedConstructors( await That(sut.GetDescription()).IsEqualTo("in the constructors ").AsPrefix(); } - [Fact] - public async Task EntryAssembly_ShouldContainExpectedAssembly() - { - Assembly? expectedAssembly = Assembly.GetEntryAssembly(); - - Filtered.Assemblies sut = In.EntryAssembly(); - -#if NET8_0_OR_GREATER - await That(sut).HasSingle().Which - .IsEqualTo(expectedAssembly); -#else - await That(sut).IsEmpty(); -#endif - await That(sut.GetDescription()).IsEqualTo("in entry assembly"); - } - [Fact] public async Task Events_WithEnumerable_ShouldContainProvidedEvents() { @@ -111,18 +95,6 @@ public async Task Events_WithEnumerable_ShouldContainProvidedEvents() await That(sut.GetDescription()).IsEqualTo("in the events ").AsPrefix(); } - [Fact] - public async Task ExecutingAssembly_ShouldContainExpectedAssembly() - { - Assembly expectedAssembly = typeof(In).Assembly; - - Filtered.Assemblies sut = In.ExecutingAssembly(); - - await That(sut).HasSingle().Which - .IsEqualTo(expectedAssembly); - await That(sut.GetDescription()).IsEqualTo("in executing assembly"); - } - [Fact] public async Task Fields_ShouldExcludeCompilerGeneratedBackingFields() { diff --git a/Tests/aweXpect.Reflection.Tests/TypesTests.cs b/Tests/aweXpect.Reflection.Tests/TypesTests.cs index 67305687..ac436db3 100644 --- a/Tests/aweXpect.Reflection.Tests/TypesTests.cs +++ b/Tests/aweXpect.Reflection.Tests/TypesTests.cs @@ -65,24 +65,6 @@ public async Task InAssemblyContaining_WithType_ShouldContainTypesFromAssemblyOf await That(sut.GetDescription()).IsEqualTo("types in assembly containing type In"); } - [Fact] - public async Task InEntryAssembly_ShouldUseEntryAssemblyAsSource() - { - Filtered.Types sut = Types.InEntryAssembly(); - - await That(sut).DoesNotContain(typeof(TypesTests)); - await That(sut.GetDescription()).IsEqualTo("types in entry assembly"); - } - - [Fact] - public async Task InExecutingAssembly_ShouldContainTypesFromExecutingAssembly() - { - Filtered.Types sut = Types.InExecutingAssembly(); - - await That(sut).Contains(typeof(In)); - await That(sut.GetDescription()).IsEqualTo("types in executing assembly"); - } - [Fact] public async Task InNamespace_ShouldContainTypesWithinNamespaceIncludingSubNamespaces() { @@ -196,26 +178,6 @@ await That(sut.GetDescription()) .IsEqualTo($"types within namespace \"{NamespaceScope}\" in assembly containing type In"); } - [Fact] - public async Task InNamespace_InEntryAssembly_ShouldUseEntryAssemblyAsSource() - { - Filtered.Types sut = Types.InNamespace(NamespaceScope).InEntryAssembly(); - - await That(sut).IsEmpty(); - await That(sut.GetDescription()) - .IsEqualTo($"types within namespace \"{NamespaceScope}\" in entry assembly"); - } - - [Fact] - public async Task InNamespace_InExecutingAssembly_ShouldUseExecutingAssemblyAsSource() - { - Filtered.Types sut = Types.InNamespace(NamespaceScope).InExecutingAssembly(); - - await That(sut).IsEmpty(); - await That(sut.GetDescription()) - .IsEqualTo($"types within namespace \"{NamespaceScope}\" in executing assembly"); - } - [Fact] public async Task InNamespace_AfterClarification_OriginalShouldStillUseAllLoadedAssemblies() { From 083c59b011952bb26c944d5c31baa41c4bba591a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Valentin=20Breu=C3=9F?= Date: Sat, 6 Jun 2026 04:42:44 +0200 Subject: [PATCH 2/6] refactor: reuse `In.Assemblies` in `InNamespaceResult.InAssemblies` The clarifier inlined a byte-for-byte copy of the `In.Assemblies` body (including the description string), the only one of the clarifiers not delegating to `In.*`. Delegate to keep the description and null handling from drifting between `Types.InAssemblies(...)` and `Types.InNamespace(...).InAssemblies(...)`. --- Source/aweXpect.Reflection/Collections/Filtered.Types.cs | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Source/aweXpect.Reflection/Collections/Filtered.Types.cs b/Source/aweXpect.Reflection/Collections/Filtered.Types.cs index ad68a6ea..bc89c767 100644 --- a/Source/aweXpect.Reflection/Collections/Filtered.Types.cs +++ b/Source/aweXpect.Reflection/Collections/Filtered.Types.cs @@ -513,8 +513,7 @@ public Types InAllLoadedAssemblies() /// Clarifies that the types within the namespace are searched in the given . /// public Types InAssemblies(params IEnumerable assemblies) - => new Assemblies(assemblies, $"in the assemblies {Formatter.Format(assemblies)}").Types() - .WithinNamespace(_namespace); + => In.Assemblies(assemblies).Types().WithinNamespace(_namespace); /// /// Clarifies that the types within the namespace are searched in the assembly that contains From 3fac7460441740b04127e2086429c598bf9bebff Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Valentin=20Breu=C3=9F?= Date: Sat, 6 Jun 2026 04:47:11 +0200 Subject: [PATCH 3/6] refactor: collapse `InNamespaceResult` clarifiers into a shared helper Each clarifier repeated `.Types().WithinNamespace(_namespace)`. The shared `From` helper makes the invariant structural: a future clarifier cannot compile without re-applying the namespace filter. --- .../aweXpect.Reflection/Collections/Filtered.Types.cs | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/Source/aweXpect.Reflection/Collections/Filtered.Types.cs b/Source/aweXpect.Reflection/Collections/Filtered.Types.cs index bc89c767..4d01b646 100644 --- a/Source/aweXpect.Reflection/Collections/Filtered.Types.cs +++ b/Source/aweXpect.Reflection/Collections/Filtered.Types.cs @@ -507,27 +507,30 @@ internal InNamespaceResult(string @namespace) /// current (the default). /// public Types InAllLoadedAssemblies() - => In.AllLoadedAssemblies().Types().WithinNamespace(_namespace); + => From(In.AllLoadedAssemblies()); /// /// Clarifies that the types within the namespace are searched in the given . /// public Types InAssemblies(params IEnumerable assemblies) - => In.Assemblies(assemblies).Types().WithinNamespace(_namespace); + => From(In.Assemblies(assemblies)); /// /// Clarifies that the types within the namespace are searched in the assembly that contains /// the . /// public Types InAssemblyContaining() - => In.AssemblyContaining().Types().WithinNamespace(_namespace); + => From(In.AssemblyContaining()); /// /// Clarifies that the types within the namespace are searched in the assembly that contains /// the . /// public Types InAssemblyContaining(Type type) - => In.AssemblyContaining(type).Types().WithinNamespace(_namespace); + => From(In.AssemblyContaining(type)); + + private Types From(Assemblies assemblies) + => assemblies.Types().WithinNamespace(_namespace); } /// From b1d5317c9665a0ac5baf9dafdf2718447a689128 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Valentin=20Breu=C3=9F?= Date: Sat, 6 Jun 2026 04:47:36 +0200 Subject: [PATCH 4/6] docs: align the `In` class summary with the `In`/`Types` split The summary still read `Static entry point for assemblies.` although `In` also selects types and members, and no longer covers selection by criteria since `In.Namespace` moved to `Types.InNamespace`. Mirror the README positioning: `In` starts from concrete reflection objects, `Types` selects by criteria. --- Source/aweXpect.Reflection/In.cs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Source/aweXpect.Reflection/In.cs b/Source/aweXpect.Reflection/In.cs index 2e256b88..ba30365c 100644 --- a/Source/aweXpect.Reflection/In.cs +++ b/Source/aweXpect.Reflection/In.cs @@ -11,8 +11,11 @@ namespace aweXpect.Reflection; /// -/// Static entry point for assemblies. +/// Static entry point for selecting assemblies, types and members from concrete reflection objects. /// +/// +/// To select types by criteria (e.g. by namespace), use instead. +/// public static class In { /// From 43e04aec7ab878843944b5d978aa2d9082d01c23 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Valentin=20Breu=C3=9F?= Date: Sat, 6 Jun 2026 04:48:07 +0200 Subject: [PATCH 5/6] style: add missing newline at end of `Types.cs` --- Source/aweXpect.Reflection/Types.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Source/aweXpect.Reflection/Types.cs b/Source/aweXpect.Reflection/Types.cs index 4448fabd..f79b6c76 100644 --- a/Source/aweXpect.Reflection/Types.cs +++ b/Source/aweXpect.Reflection/Types.cs @@ -54,4 +54,4 @@ public static Filtered.Types InAssemblyContaining(Type type) /// public static Filtered.Types.InNamespaceResult InNamespace(string @namespace) => new(@namespace); -} \ No newline at end of file +} From 61497619240ac8992bff64677efb6a3963529cdb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Valentin=20Breu=C3=9F?= Date: Sat, 6 Jun 2026 04:49:31 +0200 Subject: [PATCH 6/6] docs: document the mirroring contract between `In` and `Types` Every criteria-based source exists in three places (`In.*`, `Types.In*` and the `InNamespaceResult` clarifiers) that are only kept in sync manually; note this on the `Types` class so a new source is not added to one surface only. --- Source/aweXpect.Reflection/Types.cs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Source/aweXpect.Reflection/Types.cs b/Source/aweXpect.Reflection/Types.cs index f79b6c76..9b277302 100644 --- a/Source/aweXpect.Reflection/Types.cs +++ b/Source/aweXpect.Reflection/Types.cs @@ -8,6 +8,12 @@ namespace aweXpect.Reflection; /// /// Static entry point for selecting types by criteria. /// +/// +/// The In* methods mirror the assembly sources on (each is the corresponding +/// In.*(…).Types()) and are mirrored again as source clarifiers on +/// . When adding a new assembly source, keep all three +/// surfaces in sync. +/// public static class Types { ///