Assert Class
Additional assertions for unit tests.
Item Index
Methods
- areWithinEpsilon static
- complexWithinEpsilon static
- preserveScrollPosition static
Methods
areWithinEpsilon
(
static
-
expected -
actual -
epsilon
Asserts that the mantissas of two values are with epsilon of each other. (The test automatically fails if the exponents are different.)
complexWithinEpsilon
(
static
-
expected -
actual -
epsilon
Asserts that both real and imaginary parts of two complex values are with epsilon of each other. (The test automatically fails if the exponents are different.)
Parameters:
-
expectedComplexNumberthe expected value
-
actualComplexNumberthe actual value to test
-
epsilonComplexNumberthe maximum allowed difference in the mantissas
preserveScrollPosition
(
static
-
table -
type
Saves the current vertical scroll position and listens for the appropriate event to trigger restoring the position.
Parameters:
-
tableWidgetDataTable or BulkEditor
-
typeString"table" or "bulkeditor"
