Owns takes a condition on the claimant's answer (mayClaim): the cache arm accepts any
claimant, the cacheless arm only one of the entries the call writes. Another registered
type's record, under its current id or an old one it lists, is refused as at 0e57bf11.
Tests pin P1a/P1e/P1f shapes, the writer's own drift under a larger registry, and that a
second same-name type in the lent registry only refuses. CHANGELOG entry for the cacheless
claimant; stale comments on the store's owns predicate and WriteDocument's registry doc fixed.
Builds not yet run when committed; verified on Yggdrasil before push.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
GameCult.Caching.Tests contains NUnit tests for the caching library and its
MessagePack persistence stores.
Scope
The tests currently cover:
SingleFileMessagePackBackingStore round-trips, external pulls, and the
dirty-pull guard
DirectoryMessagePackBackingStore with the
cultcache.store.v4.directory-content-addressed-pages manifest: page writes,
clean flushes, concurrent writers under the commit lease, external deltas,
unflushed local keys, orphaned pages, and observers running after the lease
is released
CultCacheMessagePack.OpenAsync, persisted globals, dirty state, and flush on
dispose
cache lookups (Get, GetAll, runtime-type upserts)
CultCache.Commit batches on a directory store: visibility after the store
commits, abandoned stages, sealed batches, observers committing again
hand-written MessagePack snapshot and record serialization
StoreRoutingTests: the store-composition contract (routing, attachment is
hydration, read-only stores, global singletons, assignable lookups, batches,
all-or-nothing loads)
ConditionalCommitTests: Expect, ExpectUnchanged, TryCommit, the
single-file lock, strictly increasing storedAt, and the same conditions on a
directory store
DirectoryStoreDurabilityTests: failed manifest replace, content-addressed
pages, the commit lease, orphan pages and tampered pages, with faults from
real file locks
PreCut2StoreFormatTests: stores written before Cut 2 still open
Selective hydration, the directory store's stage probes, pre-v4 directory
formats, and the SoA table are no longer in the tree; the SoA table is parked
at parked/cultcache-soa (docs/parked-features.md).