You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
AssertNodeDescription{Description: "Doubles the number provided"},
175
-
NewAssertInputPortDescription("In", "The number to double"),
99
+
assertions: []nodetest.Assertion{
100
+
nodetest.NewAssertPortValue("Int", 4),
101
+
nodetest.NewAssertPortValue("Float 64", 4.),
102
+
nodetest.AssertNodeDescription{Description: "Doubles the number provided"},
103
+
nodetest.NewAssertInputPortDescription("In", "The number to double"),
176
104
},
177
105
},
178
106
"Half: nil => 0": {
179
-
node: NewNode(math.HalfNode[float64]{}),
180
-
assertions: []NodeAssert{
181
-
NewAssertPortValue("Int", 0),
182
-
NewAssertPortValue("Float 64", 0.),
107
+
node: nodetest.NewNode(math.HalfNode[float64]{}),
108
+
assertions: []nodetest.Assertion{
109
+
nodetest.NewAssertPortValue("Int", 0),
110
+
nodetest.NewAssertPortValue("Float 64", 0.),
183
111
},
184
112
},
185
113
"Half: 4 => 2": {
186
-
node: NewNode(math.HalfNode[float64]{
187
-
In: NewPortValue(4.),
114
+
node: nodetest.NewNode(math.HalfNode[float64]{
115
+
In: nodetest.NewPortValue(4.),
188
116
}),
189
-
assertions: []NodeAssert{
190
-
NewAssertPortValue("Int", 2),
191
-
NewAssertPortValue("Float 64", 2.),
192
-
AssertNodeDescription{Description: "Divides the number in half"},
193
-
NewAssertInputPortDescription("In", "The number to halve"),
117
+
assertions: []nodetest.Assertion{
118
+
nodetest.NewAssertPortValue("Int", 2),
119
+
nodetest.NewAssertPortValue("Float 64", 2.),
120
+
nodetest.AssertNodeDescription{Description: "Divides the number in half"},
121
+
nodetest.NewAssertInputPortDescription("In", "The number to halve"),
194
122
},
195
123
},
196
124
"Negate: nil => 0": {
197
-
node: NewNode(math.NegateNode[float64]{}),
198
-
assertions: []NodeAssert{
199
-
NewAssertPortValue("Out", 0.),
200
-
NewAssertInputPortDescription("In", "The number to take the additive inverse of"),
201
-
AssertNodeDescription{Description: "The additive inverse of an element x, denoted −x, is the element that when added to x, yields the additive identity, 0"},
nodetest.NewAssertInputPortDescription("In", "The number to take the additive inverse of"),
129
+
nodetest.AssertNodeDescription{Description: "The additive inverse of an element x, denoted −x, is the element that when added to x, yields the additive identity, 0"},
0 commit comments