The ntest lib enhances the rust test framework with some useful functions.
Compare floating point values or vectors of floating points wether they are approximately equal.
The default value for epsilon is
Expects a false expression. Otherwise panics.
A panic in Rust is not always implemented via unwinding, but can be implemented by aborting the process as well. This function only catches unwinding panics, not those that abort the process. See the catch unwind documentation for more information.
Expects a true expression. Otherwise panics.
Helper trait for
Test cases can be used to have multiple inputs for a given function.
The timeout attribute can be used for tests to let them fail if they exceed a certain execution time.