Expand description
Thin facade over the Antithesis SDK.
This crate owns the single antithesis feature for the project. It is no-op
unless specifically enabled. Each macro forwards to the SDK macro. These
macros convert a trailing map into JSON for consumption by the underlying
SDK.
§Use Guidance
A more precise assertion gives Antithesis better exploration. Prefer the
numeric macros like always_gt!(x, y, ...) over always!(x > y, ...).
Macros§
- always
- Asserts
conditionholds every time this line runs, and that the line runs at least once. - always_
ge - Asserts
left >= rightalways, with numeric guidance on the two operands. - always_
gt - Asserts
left > rightalways, with numeric guidance on the two operands. - always_
le - Asserts
left <= rightalways, with numeric guidance on the two operands. - always_
lt - Asserts
left < rightalways, with numeric guidance on the two operands. - always_
or_ unreachable - Asserts
conditionholds every time this line runs. Passes even if the line never runs. - always_
some - Asserts at least one of the named conditions always holds, with per-name guidance.
- reachable
- Asserts this line is reached at least once.
- sometimes
- Asserts
conditionholds at least once across all runs of this line. - sometimes_
all - Asserts every named condition holds at least once, with per-name guidance.
- sometimes_
ge - Asserts
left >= rightat least once, with numeric guidance on the two operands. - sometimes_
gt - Asserts
left > rightat least once, with numeric guidance on the two operands. - sometimes_
le - Asserts
left <= rightat least once, with numeric guidance on the two operands. - sometimes_
lt - Asserts
left < rightat least once, with numeric guidance on the two operands. - unreachable
- Asserts this line is never reached.
Functions§
- init
- Initializes the Antithesis SDK and its assertion catalog. No-op without the
antithesisfeature.