Skip to content

Commit c4a89a3

Browse files
committed
- Added Test setting for bEnableCurveEditing.
  This is to fix the failing RandomTest regression test (simple curve) due to the change in default value for bEnableCurveEditing.
1 parent d426ac5 commit c4a89a3

3 files changed

Lines changed: 10 additions & 4 deletions

File tree

Source/HoudiniEngineEditor/Private/Tests/HoudiniEditorTestUtils.cpp

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -196,12 +196,15 @@ void FHoudiniEditorTestUtils::InstantiateAsset(
196196
Wrapper->SetCookOnParameterOrInputChanges(true);
197197
Wrapper->SetCookOnTransformChange(false);
198198

199+
//
200+
Wrapper->GetHoudiniCookable()->SetEnableCurveEditing(Settings.bEnableCurveEditing);
201+
199202
TestObject->InAssetWrappers.Add(Wrapper); // Need to assign it to TestObject otherwise it will be garbage collected!!!
200203

201204
// Set properties based off test settings.
202-
Wrapper->GetHoudiniAssetComponent()->SetOverrideGlobalProxyStaticMeshSettings(true);
203-
Wrapper->GetHoudiniAssetComponent()->SetEnableProxyStaticMeshOverride(Settings.bUseProxyMesh);
204-
Wrapper->GetHoudiniAssetComponent()->SetEnableProxyStaticMeshRefinementOnPreSaveWorldOverride(!Settings.bUseProxyMesh);
205+
Wrapper->GetHoudiniCookable()->SetOverrideGlobalProxyStaticMeshSettings(true);
206+
Wrapper->GetHoudiniCookable()->SetEnableProxyStaticMeshOverride(Settings.bUseProxyMesh);
207+
Wrapper->GetHoudiniCookable()->SetEnableProxyStaticMeshRefinementOnPreSaveWorldOverride(!Settings.bUseProxyMesh);
205208

206209
// Bind delegates from the asset wrapper to UHoudiniEditorTestObject which we use to proxy to non-dynamic delegates
207210
// like OnPreInstantiation.

Source/HoudiniEngineEditor/Private/Tests/HoudiniEditorTestUtils.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,7 @@ class SWindow;
5757
struct FHoudiniActorTestSettings
5858
{
5959
bool bUseProxyMesh = false;
60+
bool bEnableCurveEditing = false;
6061
};
6162

6263
// Struct to override FAutomationTestBase behaviour as we see fit

Source/HoudiniEngineEditor/Private/Tests/HoudiniEditorTests.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,9 @@ bool HoudiniEditorRandomEquivalenceTest::RunTest(const FString & Parameters)
141141
// Really force editor size
142142
FHoudiniEditorTestUtils::InitializeTests(this, [this]
143143
{
144-
FHoudiniEditorTestUtils::RunOrSetupDifferentialTest(this, TEXT("RandomTests"), TEXT("/Game/TestHDAs/Random/simple_curve"), TEXT("simple_curve"), {}, [this](bool IsSuccessful)
144+
FHoudiniActorTestSettings Settings = {};
145+
Settings.bEnableCurveEditing = true;
146+
FHoudiniEditorTestUtils::RunOrSetupDifferentialTest(this, TEXT("RandomTests"), TEXT("/Game/TestHDAs/Random/simple_curve"), TEXT("simple_curve"), Settings, [this](bool IsSuccessful)
145147
{
146148
FHoudiniEditorTestUtils::RunOrSetupDifferentialTest(this, TEXT("RandomTests"), TEXT("/Game/TestHDAs/Random/simple_heightfield"), TEXT("simple_heightfield"), {}, [this](bool IsSuccessful)
147149
{

0 commit comments

Comments
 (0)