Class HudDefinitionScannerTests
Tests for HudDefinitionScanner, the one place HUD authoring rules live.
Every rule gets a case that fires it and the clean-element case proves it does not fire otherwise, because
a scanner that reports a finding on a correct HUD is worse than one that reports none — the author stops
reading. Each case also asserts the section, since that value is what a tool uses to open the group of
fields at fault.
Inherited Members
Namespace: Serenity.GameUi.Tests.Application
Assembly: Tests.dll
Syntax
public class HudDefinitionScannerTests
Constructors
HudDefinitionScannerTests()
Declaration
public HudDefinitionScannerTests()
Methods
ScanElement_ActiveTransformOnAnIconSetElement_ReportsADataInfo()
Declaration
public void ScanElement_ActiveTransformOnAnIconSetElement_ReportsADataInfo()
ScanElement_AnimationOnSignalWithNoSignalTypeName_ReportsAnAnimationError()
Declaration
public void ScanElement_AnimationOnSignalWithNoSignalTypeName_ReportsAnAnimationError()
ScanElement_AnimationWithNoLayerAsset_ReportsAnAnimationError()
Declaration
public void ScanElement_AnimationWithNoLayerAsset_ReportsAnAnimationError()
ScanElement_ChangeFeedbackCooldownConfiguredWithoutAnId_ReportsAnUpdatesWarning()
Declaration
public void ScanElement_ChangeFeedbackCooldownConfiguredWithoutAnId_ReportsAnUpdatesWarning()
ScanElement_ChangeFeedbackDirectionConfiguredWithoutAnId_ReportsAnUpdatesWarning()
Declaration
public void ScanElement_ChangeFeedbackDirectionConfiguredWithoutAnId_ReportsAnUpdatesWarning()
ScanElement_ChangeFeedbackIdOnADecorativeRepresentation_ReportsAnUpdatesInfo()
Declaration
public void ScanElement_ChangeFeedbackIdOnADecorativeRepresentation_ReportsAnUpdatesInfo()
ScanElement_ChangeFeedbackIdOnAValueBearingRepresentation_ReportsNoChangeFeedbackFinding()
Declaration
public void ScanElement_ChangeFeedbackIdOnAValueBearingRepresentation_ReportsNoChangeFeedbackFinding()
ScanElement_DifferentRawWatchedIdsResolvingToTheSameElement_AreFlaggedAsDuplicates()
The duplicate key is the RESOLVED watched element, not the raw authored id — an empty id (self) and
the owning element's own id explicitly spelled out resolve to the same element, so they must be
flagged as duplicates just like two identical raw ids would be. Uses the narrow overload on purpose:
this dedupe rule is local to ScanAnimations and needs no element list to resolve "self".
Declaration
public void ScanElement_DifferentRawWatchedIdsResolvingToTheSameElement_AreFlaggedAsDuplicates()
ScanElement_DuplicateAnimationEntries_ReportsAnAnimationInfo()
Declaration
public void ScanElement_DuplicateAnimationEntries_ReportsAnAnimationInfo()
ScanElement_LabelWithACaption_ScansClean()
A label element is complete when it has a caption and nothing else: no binding, no preview data.
Declaration
public void ScanElement_LabelWithACaption_ScansClean()
ScanElement_LabelWithoutACaption_SaysItRendersNothing()
Declaration
public void ScanElement_LabelWithoutACaption_SaysItRendersNothing()
ScanElement_NeedingAMaximumWithNoPreviewMaximum_ExplainsWhyItDrawsNothing()
Declaration
public void ScanElement_NeedingAMaximumWithNoPreviewMaximum_ExplainsWhyItDrawsNothing()
ScanElement_RefreshingOnAnUnnamedSignal_ReportsAnUpdatesError()
Declaration
public void ScanElement_RefreshingOnAnUnnamedSignal_ReportsAnUpdatesError()
ScanElement_RemapRangeWithADegenerateSourceRange_ReportsADataError()
Declaration
public void ScanElement_RemapRangeWithADegenerateSourceRange_ReportsADataError()
ScanElement_RenderingATextValueAsANumber_ReportsALookError()
Declaration
public void ScanElement_RenderingATextValueAsANumber_ReportsALookError()
ScanElement_RenderingAnIntegerAsASegmentedRow_ReportsNoPairingProblem()
Declaration
public void ScanElement_RenderingAnIntegerAsASegmentedRow_ReportsNoPairingProblem()
ScanElement_ReportsNothingForACorrectlyAuthoredElement()
Declaration
public void ScanElement_ReportsNothingForACorrectlyAuthoredElement()
ScanElement_SpriteStillNeedsAnId()
Declaration
public void ScanElement_SpriteStillNeedsAnId()
ScanElement_SpriteWithAStrayBinding_IsNotReportedAsAPairingFailure()
Declaration
public void ScanElement_SpriteWithAStrayBinding_IsNotReportedAsAPairingFailure()
ScanElement_SpriteWithNothingBound_ScansClean()
A sprite reads no data, so an element carrying one is complete with nothing bound and nothing to preview. Every rule that would fire here — no value binding, no preview value — is conditional on the representation actually consuming a value.
Declaration
public void ScanElement_SpriteWithNothingBound_ScansClean()
ScanElement_ThresholdBandsNotStrictlyAscending_ReportsALookError()
Declaration
public void ScanElement_ThresholdBandsNotStrictlyAscending_ReportsALookError()
ScanElement_ThresholdBandsOnAnUnsupportedRepresentation_ReportsALookWarning()
Declaration
public void ScanElement_ThresholdBandsOnAnUnsupportedRepresentation_ReportsALookWarning()
ScanElement_ThresholdBandsWithNoValueBinding_ReportsALookInfo()
Declaration
public void ScanElement_ThresholdBandsWithNoValueBinding_ReportsALookInfo()
ScanElement_ThresholdRatioModeWithNoCapacityBinding_ReportsALookError()
Declaration
public void ScanElement_ThresholdRatioModeWithNoCapacityBinding_ReportsALookError()
ScanElement_TransformOnANonNumericBinding_ReportsADataWarning()
Declaration
public void ScanElement_TransformOnANonNumericBinding_ReportsADataWarning()
ScanElement_ValueElementWithoutACaption_IsNotAskedForOne()
Declaration
public void ScanElement_ValueElementWithoutACaption_IsNotAskedForOne()
ScanElement_WellFormedAnimation_ReportsNoAnimationFinding()
Declaration
public void ScanElement_WellFormedAnimation_ReportsNoAnimationFinding()
ScanElement_WellFormedThresholdRampOnText_ReportsNoThresholdFinding()
Declaration
public void ScanElement_WellFormedThresholdRampOnText_ReportsNoThresholdFinding()
ScanElement_WithACapacityBindingThatNoLongerResolves_ReportsADataError()
Declaration
public void ScanElement_WithACapacityBindingThatNoLongerResolves_ReportsADataError()
ScanElement_WithARepresentationNeedingAMaximumButNoneAuthored_ReportsALookError()
Declaration
public void ScanElement_WithARepresentationNeedingAMaximumButNoneAuthored_ReportsALookError()
ScanElement_WithAValueBindingThatNoLongerResolves_ReportsADataError()
Declaration
public void ScanElement_WithAValueBindingThatNoLongerResolves_ReportsADataError()
ScanElement_WithAValueOfAnUnrenderableType_ReportsADataWarning()
Declaration
public void ScanElement_WithAValueOfAnUnrenderableType_ReportsADataWarning()
ScanElement_WithAZeroInterval_ReportsAnUpdatesWarning()
Declaration
public void ScanElement_WithAZeroInterval_ReportsAnUpdatesWarning()
ScanElement_WithAllElementsExplicitlyNull_SkipsCrossElementAnimationRules()
Declaration
public void ScanElement_WithAllElementsExplicitlyNull_SkipsCrossElementAnimationRules()
ScanElement_WithAllElementsGiven_AnimationWatchingAnUnknownElement_ReportsAnAnimationError()
Declaration
public void ScanElement_WithAllElementsGiven_AnimationWatchingAnUnknownElement_ReportsAnAnimationError()
ScanElement_WithAllElementsGiven_ValueTriggeredAnimationOnADecorativeElement_ReportsAnAnimationWarning()
Declaration
public void ScanElement_WithAllElementsGiven_ValueTriggeredAnimationOnADecorativeElement_ReportsAnAnimationWarning()
ScanElement_WithAnEmptyValueBinding_ReportsADataError()
Declaration
public void ScanElement_WithAnEmptyValueBinding_ReportsADataError()
ScanElement_WithAnUnknownValueKind_IsNotAlsoReportedAsAPairingFailure()
Declaration
public void ScanElement_WithAnUnknownValueKind_IsNotAlsoReportedAsAPairingFailure()
ScanElement_WithNoElementListGiven_ValueTriggeredAnimationOnADecorativeElement_ReportsNothing()
Declaration
public void ScanElement_WithNoElementListGiven_ValueTriggeredAnimationOnADecorativeElement_ReportsNothing()
ScanElement_WithNoPreviewValue_SaysWhatWillBeShown()
Declaration
public void ScanElement_WithNoPreviewValue_SaysWhatWillBeShown()
ScanElement_WithNoTransformConfigured_ReportsNoTransformFinding()
Declaration
public void ScanElement_WithNoTransformConfigured_ReportsNoTransformFinding()
ScanElement_WithoutAValueBinding_ReportsADataError()
Declaration
public void ScanElement_WithoutAValueBinding_ReportsADataError()
ScanElement_WithoutAnId_ReportsAnIdentityError()
Declaration
public void ScanElement_WithoutAnId_ReportsAnIdentityError()
Scan_AnimationWatchingAnExistingElement_ReportsNoAnimationWatchedElementFinding()
Declaration
public void Scan_AnimationWatchingAnExistingElement_ReportsNoAnimationWatchedElementFinding()
Scan_AnimationWatchingAnUnknownElement_ReportsAnAnimationError()
Declaration
public void Scan_AnimationWatchingAnUnknownElement_ReportsAnAnimationError()
Scan_ChainExceedingMaxWalkDepth_ReportsADistinctLayoutErrorFromACycle()
A chain that keeps climbing, node after distinct node, past MaxChainWalkDepth is not looping — it never revisits a parent — so it must be reported as its own finding rather than folded into "cycles back to itself", which would misdirect an author hunting for a loop that is not there.
Declaration
public void Scan_ChainExceedingMaxWalkDepth_ReportsADistinctLayoutErrorFromACycle()
Scan_ChainNestedMoreThanFourBoxesDeep_ReportsALayoutWarning()
Declaration
public void Scan_ChainNestedMoreThanFourBoxesDeep_ReportsALayoutWarning()
Scan_DanglingParent_ReportsALayoutError()
Declaration
public void Scan_DanglingParent_ReportsALayoutError()
Scan_ElementParentedToItself_ReportsALayoutError()
Declaration
public void Scan_ElementParentedToItself_ReportsALayoutError()
Scan_EveryElementFindingNamesTheElementItCameFrom()
Declaration
public void Scan_EveryElementFindingNamesTheElementItCameFrom()
Scan_ExplicitWatchedElementOnAnOnShowTrigger_ReportsAnAnimationInfo()
Declaration
public void Scan_ExplicitWatchedElementOnAnOnShowTrigger_ReportsAnAnimationInfo()
Scan_ExplicitWatchedElementOnAnOnSignalTrigger_ReportsAnAnimationInfo()
Declaration
public void Scan_ExplicitWatchedElementOnAnOnSignalTrigger_ReportsAnAnimationInfo()
Scan_FlexboxWithNoChildren_ReportsALookWarning()
Declaration
public void Scan_FlexboxWithNoChildren_ReportsALookWarning()
Scan_HudWithoutAnId_ReportsAnAssetLevelError()
Declaration
public void Scan_HudWithoutAnId_ReportsAnAssetLevelError()
Scan_HudWithoutElements_ReportsAContentWarning()
Declaration
public void Scan_HudWithoutElements_ReportsAContentWarning()
Scan_NullElement_ReportsAContentErrorAgainstItsPosition()
Declaration
public void Scan_NullElement_ReportsAContentErrorAgainstItsPosition()
Scan_ParentCycle_ReportsALayoutErrorOnEachParticipant()
Declaration
public void Scan_ParentCycle_ReportsALayoutErrorOnEachParticipant()
Scan_ParentIsNotAFlexboxRepresentation_ReportsALayoutError()
Declaration
public void Scan_ParentIsNotAFlexboxRepresentation_ReportsALayoutError()
Scan_ParentedElementWithAuthoredAnchorOrOffset_ReportsALayoutInfo()
Declaration
public void Scan_ParentedElementWithAuthoredAnchorOrOffset_ReportsALayoutInfo()
Scan_RepeatedElementId_ReportsAnIdentityErrorOnTheSecondOne()
Declaration
public void Scan_RepeatedElementId_ReportsAnIdentityErrorOnTheSecondOne()
Scan_ReportsNothingForACorrectlyAuthoredHud()
Declaration
public void Scan_ReportsNothingForACorrectlyAuthoredHud()
Scan_ReportsNothingForANullHud()
Declaration
public void Scan_ReportsNothingForANullHud()
Scan_ValueTriggeredAnimationWatchingADecorativeElement_ReportsAnAnimationWarning()
Declaration
public void Scan_ValueTriggeredAnimationWatchingADecorativeElement_ReportsAnAnimationWarning()
Scan_WellFormedFlexboxHierarchy_ReportsNoHierarchyFindings()
Declaration
public void Scan_WellFormedFlexboxHierarchy_ReportsNoHierarchyFindings()