Assert
Allows adding run-time checks to assert the validity of predicates that
should hold true in a Function's processing.
Whenever the condition specified in an Assert fails, an error will
occur to indicate the fact and the Function's processing will halt.
Properties
Assertion
The type of assertion to evaluate.
Message
The message to include in the error when the assertion fails.
See the Assertion list below for additional properties that apply to specific types of assertions.
Assertions
Are equal
Verifies that the two values specified are equal.
Applicable Properties:
- Expected - The expected value.
- Actual - The actual value.
- Tolerance - Optional. In case the values are numeric, this specifies the maximum acceptable difference between the expected and actual values.
Are not equal
Verifies that the two items specified hold different values.
Applicable Properties:
- Expected - The expected value.
- Actual - The actual value.
Contains
Asserts that the specified item is contained in the given list.
Applicable Properties:
- Item - The item to look for in the list.
- List - The list to search in for the specified item.
Greater
Verifies that the first value is greater than the second value.
Applicable Properties:
- X - The first value, expected to be greater.
- Y - The second value, expected to be less than the first.
Greater or equal
Verifies that the first value is greater than or equal to the second value.
Applicable Properties:
- X - The first value, expected to be greater or equal.
- Y - The second value, expected to be less than or equal to the first.
Less
Verifies that the first value is less than the second value.
Applicable Properties:
- X - The first value, expected to be less.
- Y - The second value, expected to be greater than the first.
Less or equal
Verifies that the first value is less than or equal to the second value.
Applicable Properties:
- X - The first value, expected to be less than or equal.
- Y - The second value, expected to be greater than or equal to the first.
Is true
Asserts that a condition is true.
Applicable Properties:
- Condition - The condition to evaluate.
Is false
Asserts that a condition is false.
Applicable Properties:
- Condition - The condition to evaluate.
Is null
Verifies that the item provided holds a null-value.
Applicable Properties:
- Item - The item to test for null.
Is not null
Verifies that the item provided does hold a value and is not null.
Applicable Properties:
- Item - The item to test for null.
Is empty
Asserts that a list or string is empty.
Applicable Properties:
- Item - The list or string to test for.
Is not empty
Asserts that a list or string is not empty.
Applicable Properties:
- Item - The list or string to test for.
Fail
Fails unconditionally. Use to verify that a specific part of a Function's processing never executes.