pub enum WriteScenario {
Create,
Abort,
CreateConflict,
Replace,
Append,
IfAbsent,
IfMatch,
AtomicReplace,
Durable,
}Expand description
The write behavior whose request a fixture prepares.
§Examples
use qubit_fs_testkit::WriteScenario;
assert_eq!(WriteScenario::Create, WriteScenario::Create);
assert_ne!(WriteScenario::Replace, WriteScenario::Append);Variants§
Create
Publish bytes to a previously absent destination.
Abort
Open a fresh CreateNew writer for explicit abort without committing.
CreateConflict
Attempt CreateNew against an independently seeded existing target.
Replace
Replace the entire contents of an existing destination. The initial contents must be longer than the payload to verify truncation.
Append
Append bytes to an existing destination. Preparation must supply nonempty initial contents for independent observation.
IfAbsent
Write with an explicit absence precondition.
IfMatch
Write with the current destination version as a precondition.
AtomicReplace
Replace an existing destination with required atomicity. Initial contents must differ from the requested replacement bytes.
Durable
Publish bytes with required durability. The prepared request uses CreateNew at a previously absent destination.