Skip to main content

Module testkit

Module testkit 

Source
Expand description

Test facilities for embedders, and for this crate’s own assurance layers.

Shipped rather than confined to tests/ because an embedder’s own store implementation and own skills need the same treatment this crate’s do, and rebuilding a fault injector per project is how each one ends up testing a slightly different, slightly weaker thing.

Behind the testkit feature, off by default, and no feature a release enables pulls it in — no_shipped_feature_enables_testkit in tests/guards/docs.rs is what makes that a fact rather than an intention.

The deterministic model is deliberately not here but in model::fake, behind fake-model, which ships: a stand-in model is a driver, while everything in this module stands in for a control.

Re-exports§

pub use memory_keyring::MemoryKeyRing;
pub use crate::model::fake::Ask;
pub use crate::model::fake::FakeProvider;
pub use backstop::assert_replay_was_not_backstopped;
pub use conformance::Report;
pub use conformance::Violation;
pub use conformance::check as check_journal_store;
pub use crash::CrashPoint;
pub use crash::assert_resumed_honestly;
pub use crash::crash_points;
pub use faults::Fault;
pub use faults::Faulty;
pub use faults::Schedule;

Modules§

backstop
The assertion that a defence-in-depth property is actually being tested.
conformance
What every journal store must do, checked against any implementation.
conformance_auth
The contract an Authenticator a deployment writes has to keep.
conformance_blob
One contract, run against every blob store.
conformance_calendar
One contract, run against every calendar.
conformance_case
What the case-layer stores must do, checked against any implementation.
conformance_keyring
One contract, run against every key ring.
conformance_policy
One contract, run against every policy engine.
conformance_push
One battery pinning every native due_in to the trait’s own default.
conformance_quota
One contract, run against every quota store.
conformance_registry
One contract, run against every manifest registry.
crash
Every point a process could have died during a recorded run.
faults
A store that fails on purpose, deterministically.
memory_keyring
A key ring in this process. For tests, and unreachable without testkit.
older_shape
An export as a build one record shape older would have written it.

Structs§

SharedJournal
A journal that claims to be shared, over one that is not.
StagedAtomic
A journal store that lends a (simulated) transaction.
StubSigner
Produces a deterministic, forgeable “signature”.

Type Aliases§

Statement
One statement a resource ran.