logo SERENITY
Game Systems Foundation
Search Results for

    Show / Hide Table of Contents

    Class UnityPrimaryInputPromptViewTests

    Tests for UnityPrimaryInputPromptView lifecycle behavior. Ensures input detection re-arms correctly after OnEnable (critical for scene reload scenarios).

    Inheritance
    object
    UnityPrimaryInputPromptViewTests
    Inherited Members
    object.ToString()
    object.Equals(object)
    object.Equals(object, object)
    object.ReferenceEquals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    Namespace: Serenity.Ui.Tests.Infrastructure.Views
    Assembly: Tests.dll
    Syntax
    public class UnityPrimaryInputPromptViewTests

    Constructors

    UnityPrimaryInputPromptViewTests()

    Declaration
    public UnityPrimaryInputPromptViewTests()

    Methods

    EnableDisableEnableCycle_ReArmsInputDetection()

    Tests the full enable/disable/enable cycle simulating scene reload behavior.

    Declaration
    public void EnableDisableEnableCycle_ReArmsInputDetection()

    OnDisable_ClearsCtsForNextOnEnable()

    Tests that OnDisable properly clears the CTS so OnEnable knows to re-arm.

    Declaration
    public void OnDisable_ClearsCtsForNextOnEnable()

    OnEnable_WhenCtsAlreadyExists_DoesNotReArm()

    Tests that OnEnable does NOT re-arm if already armed (CTS exists).

    Declaration
    public void OnEnable_WhenCtsAlreadyExists_DoesNotReArm()

    OnEnable_WhenInitializedAndCtsIsNull_CallsArmAndAwait()

    Regression test for ResetApplication bug: After scene reload, the PrimaryInputPromptView must re-arm input detection when OnEnable is called. This test verifies that OnEnable correctly triggers ArmAndAwait when the component is properly initialized.

    Declaration
    public void OnEnable_WhenInitializedAndCtsIsNull_CallsArmAndAwait()

    SetUp()

    Declaration
    public void SetUp()

    TearDown()

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