Crate substance_framework

Source

Macros§

panic
Bypass the default panic macro and redirect all its calls to our custom implementation. This is necessary to prevent unwinding and let us detect test failure with some assertions.
sf_assert
Passes if Condition is true.
sf_assert_eq
Passes if both arguments are equals.
sf_assert_ge
Passes if the left argument is strictly greater than or equals to the right one.
sf_assert_gt
Passes if the left argument is strictly greater than the right one.
sf_assert_le
Passes if the left argument is strictly smaller than or equal to the right one.
sf_assert_lt
Passes if the left argument is strictly smaller than the right one.
sf_assert_ne
Passes if both arguments are not equal.
sf_assert_ok
Passes if the argument is an Ok result.
sf_assert_some
Passes if the argument is an existing optional value.
substance_panic
Provide a panic-like macro that can be used in the framework to detect a test failure and save that status with a message for later screen printing.

Structs§

Conclusion
Struct that represent the final result of the test run to display some number.
Location
A struct containing information about the location of a panic.
PanicInfo
A struct providing information about a panic.
STATE
State
Represents the current state of the framework.
TestBlock
Struct that contain information about a test function to run.

Enums§

Outcome
Represents the outcome of a particular test.

Functions§

test_runner
abortExperimental
Aborts the execution of the process.