Class BinaryComparisonTests
Contains utilities for testing binary comparison tests, inherit when testing units that extend BinaryComparisonUnit
Inheritance
object
BinaryComparisonTests
Assembly: solution.dll
Syntax
public class BinaryComparisonTests : BaseGraphExecutionTests
Fields
FloatTestValues
Float values used for testing binary comparison units (numeric comparisons)
Declaration
public static readonly float[] FloatTestValues
Field Value
IfFalseID
ID for the TestTriggerUnit triggered when the comparison is false
Declaration
public const string IfFalseID
Field Value
IfTrueID
ID for the TestTriggerUnit triggered when the comparison is true
Declaration
public const string IfTrueID
Field Value
IntTestValues
Int values used for testing binary comparison units (numeric comparisons)
Declaration
public static readonly int[] IntTestValues
Field Value
Methods
GetNumericGraphDisconnectBuilder<U>(float, float, bool, bool, bool)
Creates a graph builder action for the given unit, connecting the desired ports.
Declaration
protected Action<FlowGraph, ControlOutput> GetNumericGraphDisconnectBuilder<U>(float lhs, float rhs, bool lhsDisconnected, bool rhsDisconnected, bool resultDisconnected) where U : BinaryComparisonUnit, new()
Parameters
Returns
Type Parameters
RunNumericTest<U>(float, float, Dictionary<string, int>, ComparisonMode)
Builds a graph for the given unit and runs the test
Declaration
protected void RunNumericTest<U>(float lhs, float rhs, Dictionary<string, int> results, BinaryComparisonTests.ComparisonMode numericMode = ComparisonMode.Numeric) where U : BinaryComparisonUnit, new()
Parameters
Type Parameters
TestBinaryComparisonPortAttributes<U>(U)
Tests the various attributes of the node ports.
Declaration
protected void TestBinaryComparisonPortAttributes<U>(U unit) where U : BinaryComparisonUnit
Parameters
| Type |
Name |
Description |
| U |
unit |
|
Type Parameters
Extension Methods