Namespace Serenity.UnityMenu.Tests.Infrastructure
Classes
CascadeMenuDefinitionIdentityTests
Tests for the CascadeMenuDefinition identity contract: every concrete cascade-menu kind (target, options, dynamic-list) implements IFoundationSettings, is assigned a non-empty Guid on creation, and round-trips its Id through the interface.
CompositeViewServiceResolverTests
Tests for CompositeViewServiceResolver: it resolves the composite-view service from the static ServiceLocatorBridge, returns null while none is registered, and caches the resolved instance on first success. Each test sets and clears the static bridge to stay isolated.
UnityMenuAnchorUtilsTests
Tests for UnityMenuAnchorUtils: the pivot/offset math derived from the shared anchor→factor mapping. Verifies pivots per anchor, the inward border-margin sign rule, and the bottom-alignment query.
UnityMenuBuildContextTests
Tests for the UnityMenuBuildContext parameter-bag DTO: it must surface the build inputs it was constructed with. The values with observable, dependency-free identity (options map, canvas, audio service id) are asserted by reference/value; the rest are passed as null to confirm verbatim storage.
UnityMenuLazyBuildContextTests
Tests for the shared UnityMenuLazyBuildContext DTO: it must surface the build inputs it was constructed with. Only the inputs with observable, dependency-free values are asserted; the rest are passed as null to confirm they are stored verbatim.
UnityMenuLazyRegistrationTests
Tests for the UnityMenuLazyRegistration DTO: it must expose the menu id, settings, and view-model passed to its constructor unchanged.
UnityMenuOptionBuildContextTests
Tests for the UnityMenuOptionBuildContext parameter-bag DTO: it must expose exactly the option, view, settings, index, and theme passed to its constructor.
UnityMenuOptionValidationServiceTests
Tests for UnityMenuOptionValidationService: TRANSITION/ACTION options skip the game-settings lookup, value-bearing options require an existing setting (otherwise throw), and the duplicate-id guard throws and logs a single error only when ids collide.
UnityMenuServiceFactoryTests
Tests for UnityMenuServiceFactory: it must build a GameObject named for the service and return the attached UnityMenuService as an IMenuService.
UnityMenuServiceSettingsDefinitionTests
Tests for the UnityMenuServiceSettingsDefinition ScriptableObject: its explicit-interface members must surface the inspector-authored public fields, including the Unity→System Vector2 conversion of the border margin.
UnityMenuSettingsDefinitionTests
Tests for the UnityMenuSettingsDefinition ScriptableObject: the explicit IMenuSettingsDefinition members must surface the inspector-authored public fields, the inherited scrollable-view fields must round-trip, and the documented enum defaults must hold.
UnityMenuSubmitServiceTests
Tests for UnityMenuSubmitService's dependency-only path DispatchOptionSignal:
each of an option's submit signals is dispatched, a null dispatcher throws, and an option with no
signals dispatches nothing. The view-coupled overloads are not exercised here (they require a fully
initialized UnityMenuView / live components).
UnityMenuThemeSoundFactoryTests
Tests for UnityMenuThemeSoundFactory: it maps each of the theme's seven SFX definitions
onto a UI-typed AudioPlayerClip on the produced IUiThemeSounds, carrying the id
and file path across.