Added node highlight, fixed temporary load to include start node as well, fixed For-Condition
This commit is contained in:
@@ -35,6 +35,7 @@ public partial class TestRunner : Node
|
||||
Run("If node evaluates inventory comparisons", TestIfNodeEvaluatesInventoryComparisons);
|
||||
Run("While node reports false conditions", TestWhileNodeReportsFalseConditions);
|
||||
Run("For node stops after configured amount", TestForNodeStopsAfterConfiguredAmount);
|
||||
Run("Runtime node keeps editor id without sharing state", TestRuntimeNodeKeepsEditorIdWithoutSharingState);
|
||||
Run("Start node succeeds immediately", TestStartNodeSucceedsImmediately);
|
||||
Run("Split node connections restore both branches", TestSplitNodeConnectionsRestoreBothBranches);
|
||||
Run("Linear node connection restores next node", TestLinearNodeConnectionRestoresNextNode);
|
||||
@@ -479,6 +480,21 @@ public partial class TestRunner : Node
|
||||
AssertEqual(NodeResult.SUCCESS, node.Execute(null, 0), "loop finished");
|
||||
}
|
||||
|
||||
private void TestRuntimeNodeKeepsEditorIdWithoutSharingState()
|
||||
{
|
||||
MoveNode editorNode = new MoveNode
|
||||
{
|
||||
targetPosition = new Vector3I(1, 0, 1)
|
||||
};
|
||||
|
||||
ProgramNode runtimeNode = editorNode.DuplicateForRuntime("MoveNode42");
|
||||
MoveNode runtimeMoveNode = runtimeNode as MoveNode;
|
||||
|
||||
AssertFalse(ReferenceEquals(editorNode, runtimeNode), "runtime node should be a copy");
|
||||
AssertEqual("MoveNode42", runtimeNode.EditorNodeId, "runtime node editor id");
|
||||
AssertEqual(editorNode.targetPosition, runtimeMoveNode.targetPosition, "runtime node parameters");
|
||||
}
|
||||
|
||||
private void TestStartNodeSucceedsImmediately()
|
||||
{
|
||||
StartNode node = new StartNode();
|
||||
|
||||
Reference in New Issue
Block a user