Skip to main content

Module contract

Module contract 

Source

Macros§

backend_contract_tests
Unified contract test macro for all backend implementations.

Structs§

ContractTestEvent
ContractTestFailure

Functions§

test_basic_read_write
test_batch_limiting
Contract test: Batch limiting returns exactly the specified number of events
test_checkpoint_independent_subscriptions
Contract test: Different subscription names have independent checkpoints
test_checkpoint_load_missing_returns_none
Contract test: Loading a non-existent checkpoint returns None
test_checkpoint_save_and_load
Contract test: Save a checkpoint and load it back
test_checkpoint_update_overwrites
Contract test: Saving a checkpoint overwrites the previous value
test_concurrent_version_conflicts
test_conflict_preserves_atomicity
test_coordination_acquire_leadership
Contract test: First instance can acquire leadership successfully
test_coordination_independent_subscriptions
Contract test: Different projectors have independent coordination (different lock keys)
test_coordination_leadership_released_on_guard_drop
Contract test: Leadership is released when guard is dropped (crash/disconnect recovery)
test_coordination_second_instance_blocked
Contract test: Second instance returns error when leadership unavailable
test_event_ordering_across_streams
Contract test: Events from multiple streams are read in global append order
test_missing_stream_reads
test_position_based_resumption
Contract test: Position-based resumption works correctly
test_stream_isolation
test_stream_prefix_filtering
Contract test: Stream prefix filtering returns only matching streams
test_stream_prefix_requires_prefix_match
Contract test: Stream prefix filtering requires true prefix match (not substring match)

Type Aliases§

ContractTestResult