class MAGES::MeshDeformations::Editor::Tests::StaticParticlesEditorTests

Overview

EditMode tests for the per-actor static particle list — the storage the Edit Particles tool writes to. Covers normalization (the sorted, duplicate-free invariant BasePhysicsActor.IsParticleStatic binary searches over), serialization onto the component, and how the list is applied to the runtime simulation mesh instance. More…

class StaticParticlesEditorTests
{
public:
    // methods

    void SetUp();
    void TearDown();
    void StaticParticles_ByDefault_IsEmpty();
    void SetStaticParticles_UnorderedInputWithDuplicates_IsNormalized();
    void SetStaticParticles_NegativeAndEmptyInput_AreHandled();
    void SetStaticParticles_IsSerializedOnTheComponent();
    void ApplyStaticParticles_PinsOnlyTheListedParticles();
    void ApplyStaticParticles_OutOfRangeIndices_AreIgnored();
    void ApplyStaticParticles_LeavesBakedKinematicParticlesStatic();
};

Detailed Documentation

EditMode tests for the per-actor static particle list — the storage the Edit Particles tool writes to. Covers normalization (the sorted, duplicate-free invariant BasePhysicsActor.IsParticleStatic binary searches over), serialization onto the component, and how the list is applied to the runtime simulation mesh instance.

DynamicSoftbodyActor stands in for any BasePhysicsActor; the behaviour under test lives entirely on the base class. The shared mesh is assigned through SerializedObject so the property setter’s editor-visualization rebuild is not triggered.