MB-11 Equivalent Mutants¶
src/MemBus.Core/Keyring.cs Normalize¶
Survivor:
Scope.TryParse(scopeText, out var scope) || scope is not null
Proof: Scope.TryParse assigns scope = null before any validation. Every false return leaves
that null value in place, including the ArgumentException catch. Every true return assigns a
non-null Scope immediately before returning. Therefore scope is not null is exactly equivalent
to the boolean result of TryParse at this call site, and both A && B and A || B reduce to A.
src/MemBus.Core/MemBusConfig.cs FromEnvironment¶
Survivor:
Uri.TryCreate(serverUrl + "", UriKind.Absolute, out var uri)
Proof: serverUrl is only parsed here for validation. The value stored in MemBusConfig.ServerUrl
is the pre-parse serverUrl, not uri. For the accepted contract, the code checks only absolute
URI, http or https scheme, and a non-empty host. Appending / before parsing does not change
those three facts for any accepted URL, and rejected inputs still fail at least one of the same
checks. The slash is parser normalization, not observable runtime configuration.