Class DiagramColumnLayoutTests
Tests for DiagramColumnLayout, extracted from
Serenity.EventDispatcher.Infrastructure.Editor.SerenitySignalFlowBrowserWindow where this
arithmetic previously had no coverage at all. Card measurement stays with the window (it needs
GUIStyle text metrics), so these tests exercise only the truncation/selection/shift decisions.
Inherited Members
Namespace: Serenity.Shared.Tests.Layout
Assembly: Tests.dll
Syntax
public class DiagramColumnLayoutTests
Constructors
DiagramColumnLayoutTests()
Declaration
public DiagramColumnLayoutTests()
Methods
BuildAssetPathSlots_EmptyList_ReturnsEmpty()
Declaration
public void BuildAssetPathSlots_EmptyList_ReturnsEmpty()
BuildAssetPathSlots_NullOrEmptyPath_TitlesAsUnnamed()
Declaration
public void BuildAssetPathSlots_NullOrEmptyPath_TitlesAsUnnamed()
BuildAssetPathSlots_PathWithNoSlash_UsesTheWholePathAsTitle()
Declaration
public void BuildAssetPathSlots_PathWithNoSlash_UsesTheWholePathAsTitle()
BuildAssetPathSlots_TitlesUseTheShortNameButSubAndTooltipKeepTheFullPath()
Declaration
public void BuildAssetPathSlots_TitlesUseTheShortNameButSubAndTooltipKeepTheFullPath()
BuildReactionSlots_EmptyList_ReturnsEmpty()
Declaration
public void BuildReactionSlots_EmptyList_ReturnsEmpty()
BuildReactionSlots_UsesTypeNameNamespaceAndAssemblyQualifiedName()
Declaration
public void BuildReactionSlots_UsesTypeNameNamespaceAndAssemblyQualifiedName()
ComputeColumnTruncation_EmptyColumn_HasNoOverflow()
Declaration
public void ComputeColumnTruncation_EmptyColumn_HasNoOverflow()
ComputeColumnTruncation_EverythingVisible_WhenExpandedEvenOverTheLimit()
Declaration
public void ComputeColumnTruncation_EverythingVisible_WhenExpandedEvenOverTheLimit()
ComputeColumnTruncation_NothingTruncated_WellBelowTheLimit()
Declaration
public void ComputeColumnTruncation_NothingTruncated_WellBelowTheLimit()
ComputeColumnTruncation_NothingTruncated_WhenTotalCountIsAtTheLimit()
Declaration
public void ComputeColumnTruncation_NothingTruncated_WhenTotalCountIsAtTheLimit()
ComputeColumnTruncation_OneOverTheLimit_StillReservesTheOverflowSlot()
Declaration
public void ComputeColumnTruncation_OneOverTheLimit_StillReservesTheOverflowSlot()
ComputeColumnTruncation_SomeTruncated_WhenCollapsedAndOverTheLimit()
Declaration
public void ComputeColumnTruncation_SomeTruncated_WhenCollapsedAndOverTheLimit()
SelectVisibleSlots_EmptySources_ReturnsEmpty()
Declaration
public void SelectVisibleSlots_EmptySources_ReturnsEmpty()
SelectVisibleSlots_Expanded_ReturnsEverySourcePlusTheShowLessOverflow()
Declaration
public void SelectVisibleSlots_Expanded_ReturnsEverySourcePlusTheShowLessOverflow()
SelectVisibleSlots_FewerSourcesThanVisibleCount_DoesNotOverrun()
Declaration
public void SelectVisibleSlots_FewerSourcesThanVisibleCount_DoesNotOverrun()
SelectVisibleSlots_NothingTruncated_ReturnsEverySourceUnchanged()
Declaration
public void SelectVisibleSlots_NothingTruncated_ReturnsEverySourceUnchanged()
SelectVisibleSlots_SingleSource_ReturnsThatOneSlotWithNoOverflow()
Declaration
public void SelectVisibleSlots_SingleSource_ReturnsThatOneSlotWithNoOverflow()
SelectVisibleSlots_Truncated_KeepsOnlyTheVisiblePrefixThenAppendsOverflow()
Declaration
public void SelectVisibleSlots_Truncated_KeepsOnlyTheVisiblePrefixThenAppendsOverflow()
ShiftSecondKindDown_BothKindsPresent_PushesOnlyTheSecondKindDown()
Declaration
public void ShiftSecondKindDown_BothKindsPresent_PushesOnlyTheSecondKindDown()
ShiftSecondKindDown_OnlyOneKindPresent_IsANoOp()
Declaration
public void ShiftSecondKindDown_OnlyOneKindPresent_IsANoOp()
ShiftSecondKindDown_SecondKindIncludesTrailingOverflowSlot_ShiftsThatSlotToo()
Declaration
public void ShiftSecondKindDown_SecondKindIncludesTrailingOverflowSlot_ShiftsThatSlotToo()
ShiftSecondKindDown_SecondKindNeverAppears_StillGrowsTotalHeightButShiftsNoSlots()
Pins an existing quirk rather than the "should be" behaviour: when hasBothKinds is true but
secondKind never actually appears among slotKinds (a caller-contract
violation — in the real window, hasBothKinds is only true when two distinct kinds were
observed, so this cannot happen there), no slot is shifted, but totalHeight still grows by
sectionHeaderHeight because that accumulation is not guarded by the same "was a start index
found" check as the columnY shift. This is the original, unmodified logic — see
ShiftSecondKindDown(float[], IReadOnlyList<int>, int, bool, float, ref float).
Declaration
public void ShiftSecondKindDown_SecondKindNeverAppears_StillGrowsTotalHeightButShiftsNoSlots()