logo SERENITY
Game Systems Foundation
Search Results for

    Show / Hide Table of Contents

    Class UnityMenuViewModelTests

    Tests for UnityMenuViewModel: reactive selection/options state, option-value replacement, and the submit/cancel flags. Pure C# view-model — no scene graph required.

    Inheritance
    object
    UnityMenuViewModelTests
    Inherited Members
    object.ToString()
    object.Equals(object)
    object.Equals(object, object)
    object.ReferenceEquals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    Namespace: Serenity.UnityMenu.Tests.InterfaceAdapters
    Assembly: Tests.dll
    Syntax
    public class UnityMenuViewModelTests

    Constructors

    UnityMenuViewModelTests()

    Declaration
    public UnityMenuViewModelTests()

    Methods

    Cancel_SetsIsCancelingTrue()

    Declaration
    public void Cancel_SetsIsCancelingTrue()

    ChangeOptionValue_MatchingId_PreservesIdViewIdAndLabel()

    Declaration
    public void ChangeOptionValue_MatchingId_PreservesIdViewIdAndLabel()

    ChangeOptionValue_MatchingId_ReplacesThatOptionsValue()

    Declaration
    public void ChangeOptionValue_MatchingId_ReplacesThatOptionsValue()

    ChangeOptionValue_UnknownId_LeavesAllOptionsUnchanged()

    Declaration
    public void ChangeOptionValue_UnknownId_LeavesAllOptionsUnchanged()

    Constructor_InitializesSelectedIndexToZero()

    Declaration
    public void Constructor_InitializesSelectedIndexToZero()

    Constructor_InitializesSubmittingAndCancelingToFalse()

    Declaration
    public void Constructor_InitializesSubmittingAndCancelingToFalse()

    Constructor_StoresProvidedOptions()

    Declaration
    public void Constructor_StoresProvidedOptions()

    GetId_ReturnsConstructorId()

    Declaration
    public void GetId_ReturnsConstructorId()

    GetOptionByIndex_IndexBeyondLength_Throws()

    Declaration
    public void GetOptionByIndex_IndexBeyondLength_Throws()

    GetOptionByIndex_NegativeIndex_Throws()

    Declaration
    public void GetOptionByIndex_NegativeIndex_Throws()

    GetOptionByIndex_ValidIndex_ReturnsOption()

    Declaration
    public void GetOptionByIndex_ValidIndex_ReturnsOption()

    GetSelectedOption_ReturnsOptionAtSelectedIndex()

    Declaration
    public void GetSelectedOption_ReturnsOptionAtSelectedIndex()

    SelectOption_UpdatesSelectedIndex()

    Declaration
    public void SelectOption_UpdatesSelectedIndex()

    SubmitOption_SetsIsSubmittingTrue()

    Declaration
    public void SubmitOption_SetsIsSubmittingTrue()
    In this article
    © 2026 Serenity. All Rights Reserved