UnittestAux RΒΆ
unittest.spad line 376 [edit on github]
R: BasicType
UnittestAux is an auxiliary package to Unittest, that performs checking of tests, dealing also with fatal errors.
- testAbsolutePrecision: R -> R if R has RealNumberSystem
testAbsolutePrecision(eps)returns the current absolute precision used for floating point comparison, and then sets it toeps. The default value is 1.0e-15.
- testComplexEqualsAux: (String, Complex R, Complex R) -> Void if R has RealNumberSystem
testComplexEqualsAux(inp ex1, ex2)states thatex1andex2should be approximately equal as complex numbers, taking into acount testAbsolutePrecision and testRelativePrecision.
- testEqualsAux: (String, R, R) -> Void
testEquals(inp,
ex1,ex2) states thatex1andex2should be equal. To sidestep the possibility that the equality function of the domainRperforms some simplifications, we convertex1andex2toInputForm, if possible.
- testEqualsAuxCmp: (R, R) -> Boolean
testEqualsAuxCmp shouldbe local but is conditional
- testLibraryErrorAux: (String, R) -> Void
testLibraryErrorAux(inp, ex)states that ex should throw an error. Such a test will never count as a fatal error.
- testNotEqualsAux: (String, R, R) -> Void
testNotEquals(inp,
ex1,ex2) states thatex1andex2should be different.
- testRealEqualsAux: (String, R, R) -> Void if R has RealNumberSystem
testRealEqualsAux(inp, ex1, ex2)states thatex1andex2should be approximately equal as real numbers, taking into acount testAbsolutePrecision and testRelativePrecision.
- testRelativePrecision: R -> R if R has RealNumberSystem
testRelativePrecision(eps)returns the current absolute precision used for floating point comparison, and then sets it toeps. The default value is 1.0e-15.
- xftestComplexEqualsAux: (String, Complex R, Complex R) -> Void if R has RealNumberSystem
like testEquals, but expects failure.
- xftestRealEqualsAux: (String, R, R) -> Void if R has RealNumberSystem
like testEquals, but expects failure.