Skip to content

Commit

Permalink
Make the test a bit stronger.
Browse files Browse the repository at this point in the history
  • Loading branch information
D8H committed Nov 25, 2024
1 parent a4875dc commit 4e2ab83
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions Core/tests/WholeProjectRefactorer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3083,7 +3083,7 @@ TEST_CASE("WholeProjectRefactorer", "[common]") {
project, behaviorAction.GetEvents(), "MyProperty");
auto &instruction2 = CreateInstructionWithNumberParameter(
project, behaviorAction.GetEvents(),
"MyExtension::GetVariableAsNumber(MyVariable[MyProperty])");
"MyExtension::GetVariableAsNumber(MyVariable.MyChild[MyProperty])");

gd::WholeProjectRefactorer::RenameEventsBasedBehaviorProperty(
project, eventsExtension, eventsBasedBehavior, "MyProperty",
Expand All @@ -3092,7 +3092,7 @@ TEST_CASE("WholeProjectRefactorer", "[common]") {
REQUIRE(instruction.GetParameter(0).GetPlainString() ==
"MyRenamedProperty");
REQUIRE(instruction2.GetParameter(0).GetPlainString() ==
"MyExtension::GetVariableAsNumber(MyVariable[MyRenamedProperty])");
"MyExtension::GetVariableAsNumber(MyVariable.MyChild[MyRenamedProperty])");
}

SECTION("(Events based behavior) property not renamed (in variable parameter)") {
Expand Down Expand Up @@ -3194,7 +3194,7 @@ TEST_CASE("WholeProjectRefactorer", "[common]") {
project, behaviorAction.GetEvents(), "MySharedProperty");
auto &instruction2 = CreateInstructionWithNumberParameter(
project, behaviorAction.GetEvents(),
"MyExtension::GetVariableAsNumber(MyVariable[MySharedProperty])");
"MyExtension::GetVariableAsNumber(MyVariable.MyChild[MySharedProperty])");

gd::WholeProjectRefactorer::RenameEventsBasedBehaviorSharedProperty(
project, eventsExtension, eventsBasedBehavior, "MySharedProperty",
Expand All @@ -3203,7 +3203,7 @@ TEST_CASE("WholeProjectRefactorer", "[common]") {
REQUIRE(instruction.GetParameter(0).GetPlainString() ==
"MyRenamedSharedProperty");
REQUIRE(instruction2.GetParameter(0).GetPlainString() ==
"MyExtension::GetVariableAsNumber(MyVariable[MyRenamedSharedProperty])");
"MyExtension::GetVariableAsNumber(MyVariable.MyChild[MyRenamedSharedProperty])");
}

SECTION("(Events based object) property renamed") {
Expand Down Expand Up @@ -3253,7 +3253,7 @@ TEST_CASE("WholeProjectRefactorer", "[common]") {
project, behaviorAction.GetEvents(), "MyProperty");
auto &instruction2 = CreateInstructionWithNumberParameter(
project, behaviorAction.GetEvents(),
"MyExtension::GetVariableAsNumber(MyVariable[MyProperty])");
"MyExtension::GetVariableAsNumber(MyVariable.MyChild[MyProperty])");

gd::WholeProjectRefactorer::RenameEventsBasedObjectProperty(
project, eventsExtension, eventsBasedObject, "MyProperty",
Expand All @@ -3262,7 +3262,7 @@ TEST_CASE("WholeProjectRefactorer", "[common]") {
REQUIRE(instruction.GetParameter(0).GetPlainString() ==
"MyRenamedProperty");
REQUIRE(instruction2.GetParameter(0).GetPlainString() ==
"MyExtension::GetVariableAsNumber(MyVariable[MyRenamedProperty])");
"MyExtension::GetVariableAsNumber(MyVariable.MyChild[MyRenamedProperty])");
}

SECTION("(Events based object) property not renamed (in variable parameter)") {
Expand Down

0 comments on commit 4e2ab83

Please sign in to comment.