Skip to content

Commit

Permalink
input symbol nodes should have default names
Browse files Browse the repository at this point in the history
  • Loading branch information
mjkkirschner committed May 6, 2024
1 parent 9257a46 commit 6564bd0
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/DynamoCore/Graph/Nodes/CustomNodes/Function.cs
Original file line number Diff line number Diff line change
Expand Up @@ -388,8 +388,8 @@ public Symbol()
RegisterAllPorts();

ArgumentLacing = LacingStrategy.Disabled;

InputSymbol = String.Empty;
//TODO localize
InputSymbol = new TypedParameter($"DefaultInputName", "var",-1,null).ToCommentNameString();

ElementResolver = new ElementResolver();
}
Expand Down Expand Up @@ -463,7 +463,7 @@ public string InputSymbol
}

OnNodeModified();
RaisePropertyChanged("InputSymbol");
RaisePropertyChanged(nameof(InputSymbol));
}
}

Expand Down
6 changes: 6 additions & 0 deletions test/DynamoCoreTests/CustomNodes.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1423,5 +1423,11 @@ public void LooseCustomNodeShouldNotHavePackageInfoOrPackageMember()
Assert.IsFalse(nodeInfo.Value.IsPackageMember);
Assert.IsNull(nodeInfo.Value.PackageInfo);
}
[Test]
public void InputNodeShouldHaveNameByDefault()
{
var input = new Symbol();
Assert.NotNull(input.Parameter.Name);
}
}
}

0 comments on commit 6564bd0

Please sign in to comment.