Expand description
Convenience to import all macros and functions
Re-exports§
pub use crate::assert::assert_raw;pub use crate::assert::AssertType;pub use crate::antithesis_init;pub use crate::lifecycle;pub use crate::random;
Macros§
- assert_
always - Assert that
conditionis true every time this function is called, and that it is called at least once. The corresponding test property will be viewable in theAntithesis SDK: Alwaysgroup of your triage report. - assert_
always_ greater_ than assert_always_greater_than(x, y, ...)is mostly equivalent toassert_always!(x > y, ...), except Antithesis has more visibility to the value ofxandy, and the assertion details would be merged with{"left": x, "right": y}.- assert_
always_ greater_ than_ or_ equal_ to assert_always_greater_than_or_equal_to(x, y, ...)is mostly equivalent toassert_always!(x >= y, ...), except Antithesis has more visibility to the value ofxandy, and the assertion details would be merged with{"left": x, "right": y}.- assert_
always_ less_ than assert_always_less_than(x, y, ...)is mostly equivalent toassert_always!(x < y, ...), except Antithesis has more visibility to the value ofxandy, and the assertion details would be merged with{"left": x, "right": y}.- assert_
always_ less_ than_ or_ equal_ to assert_always_less_than_or_equal_to(x, y, ...)is mostly equivalent toassert_always!(x <= y, ...), except Antithesis has more visibility to the value ofxandy, and the assertion details would be merged with{"left": x, "right": y}.- assert_
always_ or_ unreachable - Assert that
conditionis true every time this function is called. The corresponding test property will pass even if the assertion is never encountered. This test property will be viewable in theAntithesis SDK: Alwaysgroup of your triage report. - assert_
always_ some assert_always_some({a: x, b: y, ...})is similar toassert_always(x || y || ...), except:- assert_
reachable - Assert that a line of code is reached at least once.
The corresponding test property will pass if this macro is ever called. (If it is never called the test property will therefore fail.)
This test property will be viewable in the
Antithesis SDK: Reachablity assertionsgroup. - assert_
sometimes - Assert that
conditionis true at least one time that this function was called. (If the assertion is never encountered, the test property will therefore fail.) This test property will be viewable in theAntithesis SDK: Sometimesgroup. - assert_
sometimes_ all assert_sometimes_all({a: x, b: y, ...})is similar toassert_sometimes(x && y && ...), except:- assert_
sometimes_ greater_ than assert_sometimes_greater_than(x, y, ...)is mostly equivalent toassert_sometimes!(x > y, ...), except Antithesis has more visibility to the value ofxandy, and the assertion details would be merged with{"left": x, "right": y}.- assert_
sometimes_ greater_ than_ or_ equal_ to assert_sometimes_greater_than_or_equal_to(x, y, ...)is mostly equivalent toassert_sometimes!(x >= y, ...), except Antithesis has more visibility to the value ofxandy, and the assertion details would be merged with{"left": x, "right": y}.- assert_
sometimes_ less_ than assert_sometimes_less_than(x, y, ...)is mostly equivalent toassert_sometimes!(x < y, ...), except Antithesis has more visibility to the value ofxandy, and the assertion details would be merged with{"left": x, "right": y}.- assert_
sometimes_ less_ than_ or_ equal_ to assert_sometimes_less_than_or_equal_to(x, y, ...)is mostly equivalent toassert_sometimes!(x <= y, ...), except Antithesis has more visibility to the value ofxandy, and the assertion details would be merged with{"left": x, "right": y}.- assert_
unreachable - Assert that a line of code is never reached.
The corresponding test property will fail if this macro is ever called.
(If it is never called the test property will therefore pass.)
This test property will be viewable in the
Antithesis SDK: Reachablity assertionsgroup.