Class FoundationReferenceContractsTests
Anti-drift tests for FoundationReferenceContracts: every row must name a real owner
type, a serialized property that actually resolves on a scratch instance of it, and (when fixed) a
real referenced type implementing IFoundationSettings — the same guarantee
GameSettingWiringMap's own field-reflection test gives its narrower table. Owner types are
resolved purely by name (GetTypeFromCurrentDomainAssemblies(string)), so this
assembly needs no reference to Menu, Modal, GameSettings, Leaderboard, Achievements, Feedback,
GameGraphics, Localization or EventDispatcher — exactly the decoupling SerenityDiscoveryRegistry
already relies on.
Inherited Members
Namespace: Serenity.UnityValidation.Tests.Editor
Assembly: Serenity.UnityValidation.Tests.Editor.dll
Syntax
public class FoundationReferenceContractsTests
Constructors
FoundationReferenceContractsTests()
Declaration
public FoundationReferenceContractsTests()
Methods
Contracts_ContainNoDuplicateOwnerPathKindSelectorTuples()
Declaration
public void Contracts_ContainNoDuplicateOwnerPathKindSelectorTuples()
Contracts_DeclareATransitionOptionsValueGuidAsAViewKey()
Declaration
public void Contracts_DeclareATransitionOptionsValueGuidAsAViewKey()
Contracts_ForTheMenuAndModalOptionShape_AreTheSameDeclarationReadFromTwoOwners()
Declaration
public void Contracts_ForTheMenuAndModalOptionShape_AreTheSameDeclarationReadFromTwoOwners()
Contracts_OnShippedContent_ReportNoDanglingReferenceOutsideTheKnownDefects()
The dangling-reference oracle against REAL shipped content, run over Serenity.Global.Infrastructure.Editor.SerenityEditorPaths.PackageRoots only (a project the agent's package is installed into may carry its own, unrelated authoring bugs outside those roots): every Error the contract table + walker + validator produce there must be one of the known, documented shipped authoring defects in Serenity.UnityValidation.Tests.Editor.FoundationReferenceContractsTests.KnownShippedDefects — never fewer (a defect silently fixed here without updating the list) and never more (either a genuinely new shipped authoring bug, or a contract-table regression re-introducing a false positive the earlier rows in this file already fixed once).
Declaration
public void Contracts_OnShippedContent_ReportNoDanglingReferenceOutsideTheKnownDefects()
DistinctReferenceGroups_OnShippedContent_ReportNoSharedTarget()
The shipped-content oracle for FoundationDistinctReferenceGroups: no asset under Serenity.Global.Infrastructure.Editor.SerenityEditorPaths.PackageRoots may point two fields of one group at the same asset. The shipped localization settings' two language keys are what this guards — a project adopting them inherits whatever they say, so the mistake has to be absent at the source.
Declaration
public void DistinctReferenceGroups_OnShippedContent_ReportNoSharedTarget()
EveryContract_HasNonEmptyDocumentation()
Declaration
public void EveryContract_HasNonEmptyDocumentation()
EveryContract_OwnerTypeName_ResolvesToARealType()
Declaration
public void EveryContract_OwnerTypeName_ResolvesToARealType()
EveryContract_PropertyPath_ResolvesOnAScratchInstanceOfItsOwnerType()
Declaration
public void EveryContract_PropertyPath_ResolvesOnAScratchInstanceOfItsOwnerType()
EveryContract_ReferencedTypeNamePropertyPath_ResolvesToAStringPropertyOnTheOwner()
Declaration
public void EveryContract_ReferencedTypeNamePropertyPath_ResolvesToAStringPropertyOnTheOwner()
EveryContract_ReferencedTypeName_ResolvesAndImplementsFoundationSettings()
Declaration
public void EveryContract_ReferencedTypeName_ResolvesAndImplementsFoundationSettings()
EveryDeclarationInTheProject_SitsOnAStringTheFieldGraphCanRead()
Declaration
public void EveryDeclarationInTheProject_SitsOnAStringTheFieldGraphCanRead()
EveryDistinctReferenceGroup_NamesPropertyPathsTheContractTableAlsoDeclares()
Declaration
public void EveryDistinctReferenceGroup_NamesPropertyPathsTheContractTableAlsoDeclares()
EveryReferencedTypeName_HasADisplayNameThatIsNotATypeName()
Declaration
public void EveryReferencedTypeName_HasADisplayNameThatIsNotATypeName()
ForOwnerTypeOrBase_ChainWithOwnerType_ReturnsItsRows()
Declaration
public void ForOwnerTypeOrBase_ChainWithOwnerType_ReturnsItsRows()
ForOwnerTypeOrBase_EmptyChain_ReturnsEmpty()
Declaration
public void ForOwnerTypeOrBase_EmptyChain_ReturnsEmpty()
ForOwnerType_FiltersByExactOwnerTypeName()
Declaration
public void ForOwnerType_FiltersByExactOwnerTypeName()