Fix unit test

Signed-off-by: rhhong <rhhong@amazon.com>
This commit is contained in:
rhhong
2021-08-24 11:36:13 -07:00
parent 5369df4195
commit 4767d2a891
31 changed files with 341 additions and 232 deletions
@@ -23,6 +23,7 @@
#include <Editor/ReselectingTreeView.h>
#include <Tests/TestAssetCode/SimpleActors.h>
#include <Tests/TestAssetCode/ActorFactory.h>
#include <Tests/TestAssetCode/TestActorAssets.h>
#include <Tests/UI/ModalPopupHandler.h>
#include <Tests/UI/UIFixture.h>
#include <Tests/D6JointLimitConfiguration.h>
@@ -52,9 +53,11 @@ namespace EMotionFX
{
RecordProperty("test_case_id", "C14603914");
AutoRegisteredActor actor = ActorFactory::CreateAndInit<SimpleJointChainActor>(7, "CanAddToSimulatedObjectActor");
ActorInstance* actorInstance = ActorInstance::Create(actor.get());
AZ::Data::AssetId actorAssetId("{5060227D-B6F4-422E-BF82-41AAC5F228A5}");
AZ::Data::Asset<Integration::ActorAsset> actorAsset =
TestActorAssets::CreateActorAssetAndRegister<SimpleJointChainActor>(actorAssetId, 7, "CanAddToSimulatedObjectActor");
Actor* actor = actorAsset->GetActor();
ActorInstance* actorInstance = ActorInstance::Create(actor);
// Change the Editor mode to Simulated Objects
EMStudio::GetMainWindow()->ApplicationModeChanged("SimulatedObjects");
@@ -165,9 +168,11 @@ namespace EMotionFX
});
RecordProperty("test_case_id", "C13291807");
AutoRegisteredActor actor = ActorFactory::CreateAndInit<SimpleJointChainActor>(7, "CanAddToSimulatedObjectActor");
ActorInstance* actorInstance = ActorInstance::Create(actor.get());
AZ::Data::AssetId actorAssetId("{5060227D-B6F4-422E-BF82-41AAC5F228A5}");
AZ::Data::Asset<Integration::ActorAsset> actorAsset =
TestActorAssets::CreateActorAssetAndRegister<SimpleJointChainActor>(actorAssetId, 7, "CanAddToSimulatedObjectActor");
Actor* actor = actorAsset->GetActor();
ActorInstance* actorInstance = ActorInstance::Create(actor);
// Change the Editor mode to Physics
EMStudio::GetMainWindow()->ApplicationModeChanged("Physics");