- tests/conformance/fleet_column.rs (cfg feature = "postgres"; the consolidation pieces cfg the postgres+pg-lo pair): the fleet-validity rows, the joint entry+pin tx rows (both-or-neither over an independent connection; the dedup re-put's upsert-renew; the second instance's re-put composing a second row — protection by row; the pg-lo consolidation round-trip byte-exact over the shared instance), the TTL/renewal rows (the guard's TTL/3 cadence through the short test TTL; the never-resurrect semantics through the facade; the paused holder's expiry boundary with the delete-then-recover backstop), and the exact-count fleet sweep rows — the wave's gate, INV-4's engine-gated fleet form: the two-instance exact-count shape, the lease contention row (SweeperLock as report data, nothing deleted), the cross-instance arbitration row (GcRefuse until the foreign row's expiry), the race across the window delay closed by the row, the maintenance step's exact reap, and the fleet liveness verb row (the schema-ownership rule asserted; the deregistration correction flow); the kv-only rejection row mirrored verbatim against the fleet kv-only factory - three fleet factories after the postgres column's registry pattern extended to the fleet shape — one minted schema, two Store instances over it, each its own owner id (the pin rows compose by owner); the dual-tier instances carry private local roots riding FleetSharedMedia::asserted; the consolidation factory follows the pg-lo column's LO-isolation corollary (a TrackedDb::new constructor added to pg_lo_column.rs for the private janitor field); teardown drops exactly the minted schemas — idempotent, owned, panicking-row-safe, structurally exercised - the SKIP posture rides the postgres column's reachability probe: server-less runs skip cleanly, acceptance is green against pglo-poc (:15432) under --features postgres with the consolidation rows under --all-features; the test tuning is the window delay 0 and the short test pin TTL (the fleet constructors' parameter) — ordering rides the tunings or the manual-expiry instrument, no sleep-based race assertions - README amended: the fleet rows table (§Columns beyond the reference set), §Column plan (the fleet column is the wave-6 gate's host), §Current state — six columns - task suite-column-fleet completed (Notes + Summary recorded, including the recorded deviations: the structural predicate shapes reach no fleet constructor; the cross-instance mismatch leg is unexercisable on the one-instance harness server — the probe's errors-closed posture asserted instead) Verification: cargo test (default) green; cargo test --features postgres green server-less (skipping) and green against the harness server; cargo test --all-features green against the server (125 conformance + 226 library tests); cargo clippy --all-targets -- -D warnings and cargo fmt --check green on the default, postgres, and all-features variants
82 lines
3.6 KiB
Rust
82 lines
3.6 KiB
Rust
//! `main.rs` — the conformance test target's root.
|
|
//!
|
|
//! The suite is in-crate by decided point (docs/plans/implementation.md):
|
|
//! engines are features of one crate, so the harness is factory-
|
|
//! parameterized over engine constructors rather than a sibling suite
|
|
//! crate. This target carries the skeleton (factory trait shape, the
|
|
//! stamp convention, the invariant backlog registry — see
|
|
//! [`README`](./README.md)) plus the **wave-2 factory binding**: the
|
|
//! `Store` facade type landed as the concrete `alkblobs::Store`
|
|
//! (engine-blind; src/store.rs holds the engine-representation design
|
|
//! point), and the skeleton's `Store` associated type collapsed into
|
|
//! it — `open` vends the concrete facade type directly, recorded in
|
|
//! `factory.rs` and the README. The wave-1 mock probe retired with it;
|
|
//! the binding demonstrator ([`binding`], mem-gated — mem is the
|
|
//! skip-free reference shape) proves the contract implementable
|
|
//! against the real type.
|
|
//!
|
|
//! The reference rows landed with wave 2's mem column: [`rows`] holds
|
|
//! the reference row set (INV-1…6 plus the two constructor-mode rows,
|
|
//! ADR-stamped, traced to [`backlog`]); the columns' records live in
|
|
//! their module docs ([`README`](./README.md) §The reference row set
|
|
//! is the recorded inventory other columns mirror).
|
|
//!
|
|
//! The columns: [`mem_column`] — the contract-reference column;
|
|
//! [`local_column`] — the suite's first dual-tier column (the
|
|
//! `kv = mem` + `large = local` dispatch-coverage shape ADR-012 §6.3
|
|
//! names), which mirrors the reference set and grows the
|
|
//! dispatch-coverage and local-specific rows; [`sqlite_column`] — the
|
|
//! suite's first SQL-backed column (the default-build production
|
|
//! shape, `kv = sqlite` + `large = local`), which mirrors the
|
|
//! form-independent reference rows and grows the durable-schedule
|
|
//! sweep rows (README §The schedule-relative reading for SQL-backed
|
|
//! columns); [`postgres_column`] — the suite's first SKIP-posture
|
|
//! column (the fleet-capable-kv shape, `kv = postgres` + `large =
|
|
//! `local`, feature `postgres` default-off), which mirrors the same
|
|
//! sets against the harness server and skips cleanly server-less;
|
|
//! [`pg_lo_column`] — the suite's second SKIP-posture column (the
|
|
//! LO-medium column, feature `pg-lo` default-off, its two factories
|
|
//! spanning feature pairs `mem`+`pg-lo` and `postgres`+`pg-lo`), which
|
|
//! runs the same sets against the LO medium and skips cleanly
|
|
//! server-less; [`fleet_column`] — the suite's third SKIP-posture
|
|
//! column (the fleet column — the exact-count fleet sweep outcomes
|
|
//! under concurrency, wave 6's gate, feature `postgres`-gated, its
|
|
//! consolidation factory also gated on `pg-lo`), which runs the
|
|
//! fleet-validity rows, the joint-tx rows, the TTL/renewal rows, and
|
|
//! the engine-gated fleet-form sweep rows against two store instances
|
|
//! over one shared pool and skips cleanly server-less.
|
|
//!
|
|
//! Items beyond the tests below are the later columns' surface, hence
|
|
//! the scoped `#![allow(dead_code)]` — it shrinks as columns land.
|
|
|
|
#![allow(dead_code)]
|
|
|
|
mod backlog;
|
|
#[cfg(feature = "mem")]
|
|
mod binding;
|
|
mod factory;
|
|
#[cfg(feature = "postgres")]
|
|
mod fleet_column;
|
|
#[cfg(feature = "mem")]
|
|
mod local_column;
|
|
#[cfg(feature = "mem")]
|
|
mod mem_column;
|
|
#[cfg(feature = "pg-lo")]
|
|
mod pg_lo_column;
|
|
#[cfg(feature = "postgres")]
|
|
mod postgres_column;
|
|
mod rows;
|
|
#[cfg(feature = "sqlite")]
|
|
mod sqlite_column;
|
|
mod stamp;
|
|
|
|
#[test]
|
|
fn stamp_marker_matches_convention() {
|
|
assert_eq!(stamp::STAMP_MARKER, "Contract stamp:");
|
|
}
|
|
|
|
#[test]
|
|
fn backlog_registers_the_seven_invariants() {
|
|
backlog::assert_traceable();
|
|
}
|