CultLib/tests/GameCult.Caching.Tests
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Meta Vens 908d9ac29d Codec: StandardResolverAllowPrivate's formatter for an id-path type is no claim
It writes the [Key] layout plus non-public keyed members, and registration now refuses any of those that
reaches an object list, so no element id can be dropped. The comparison is made lazily, only after an
ahead resolver returned a non-standard formatter, and an exception from it reads as not equal.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-15 01:23:40 +02:00
..
Fixtures Mark pre-Cut 2 store fixtures binary 2026-09-13 17:17:49 +02:00
AssemblyInfo.cs UnionArmGuardTests: a later resolver's claim on a type the standard formatter already answered is never asked 2026-10-15 00:35:57 +02:00
BackingStoreTests.cs Mark the three share-mode tests Windows-only 2026-09-29 04:17:31 +02:00
CompatibleSchemaIdTests.cs Tests: a record a type reads but no type declares is read-only on every cache write path 2026-10-03 12:34:58 +02:00
ConditionalCommitTests.cs CultCache: the store owns a file's bytes, not the record object 2026-10-03 10:47:30 +02:00
CultAssetGuidKeyTests.cs Studio: refuse built-ins by asset identity, not GUID digits; add Clear for stale keys 2026-09-17 20:09:53 +02:00
CultCacheClockTests.cs Union golden: the store's clock is an internal seam, the writer pins it, the gate test runs under any switch 2026-10-11 02:58:54 +02:00
CultCacheJournalTests.cs Journal registration counts as disposed only once removal succeeds; a throwing hold body surfaces journal failures 2026-09-29 20:35:50 +02:00
CultCacheObserverTests.cs Keep the test frame from holding the subscription it checks the cache released 2026-09-29 20:03:08 +02:00
CultCacheProjectionTests.cs Kill the Stryker survivors in the projection and observer cuts 2026-09-29 17:46:36 +02:00
CultDocumentRegistryTests.cs CultCache: a second type for one schema is refused, typed 2026-09-30 16:15:57 +02:00
CultDocumentSelectionSurfaceTests.cs R-AL/R-AM/R-AO: C# regression tests for the fix batch 2026-09-23 07:17:21 +02:00
CultInspectorModelTests.cs Cover valid surrogate pairs and a second unpaired surrogate in node ids 2026-09-29 15:49:51 +02:00
CultMathExprSerializationTests.cs ExprGraph resolver: nil is nil, decode refuses non-canonical encodings, pin nested shape, nil-name and depth rules 2026-10-14 07:54:32 +02:00
CultMathExprVariantTests.cs Caching.Tests: an ExprGraph record survives a cache, is inherited or overridden whole by variants, and follows its base 2026-10-14 20:31:44 +02:00
CultMathJsonTests.cs Caching: JSON converter and MessagePack formatter for CultPhasor 2026-09-30 02:46:29 +02:00
CultMathSerializationTests.cs Caching: JSON converter and MessagePack formatter for CultPhasor 2026-09-30 02:46:29 +02:00
DirectoryStoreDurabilityTests.cs Mark the three share-mode tests Windows-only 2026-09-29 04:17:31 +02:00
DocumentShapeTests.cs Persist get-only and readonly members the way MessagePack does 2026-09-14 00:21:21 +02:00
ElementIdEngineTests.cs Element ids: a non-public [Key] member on the way to an object list is refused at registration 2026-10-15 01:22:47 +02:00
ElementIdTests.cs ElementIdTests: the staged-holds-an-id gate is pinned with two written records, only one holding an id 2026-10-14 23:48:21 +02:00
EmittedDocumentTypes.cs C#: a type listing an id registers beside the type that owns it; the owner wins 2026-09-30 15:26:06 +02:00
ForeignRecordTests.cs JudgeChecks lock contract: tests pin the read-after-lock order and the directory judge's wait=false 2026-10-14 03:14:46 +02:00
GameCult.Caching.Tests.csproj Delete the CultCache MessagePack source generator 2026-09-13 23:38:08 +02:00
NumericLeafVectorTests.cs Caching.Tests fixtures: element ids are 12-hex literals, the form the id rule accepts 2026-10-14 19:41:50 +02:00
PayloadDepthTests.cs Payload depth tests: the largest fixmap and a container header cut short at the limit 2026-10-11 08:58:50 +02:00
PreCut2FixtureDocuments.cs Mark every Cult document [MessagePackObject] 2026-09-13 23:38:08 +02:00
PreCut2StoreFormatTests.cs C# tests: the directory refusal shows a header only as store version digits, so the suffixed legacy names are no longer echoed 2026-10-02 21:00:51 +02:00
PythonWrittenStoreTests.cs Tests: the Mesh test's unmarked file holds ids of a type defined in the Mesh assembly (a persisted layout is matched by CLR type name); the appended python record brings its catalog entry beside the cache's 2026-10-14 23:39:50 +02:00
README.md Delete the CultCache MessagePack source generator 2026-09-13 23:38:08 +02:00
SerializationOptionsTests.cs Write an unset CultRecordRef as "" in every position 2026-09-14 21:34:23 +02:00
SlotNilVectorTests.cs Caching and cultcache-ts tests: slot-nil rows for a four-byte UTF-8 character in a string slot and in a byte[] slot 2026-10-12 00:08:23 +02:00
StoreReadabilityTests.cs Tests: version identity (rewrite at the same storedAt, pull arrival, ExpectUnchanged, staleness check, own-write version, in-memory, SHA-256 definition) 2026-10-03 08:23:31 +02:00
StoreRoutingTests.cs Mark the three share-mode tests Windows-only 2026-09-29 04:17:31 +02:00
StoreSlices.cs CultCache: the store owns a file's bytes, not the record object 2026-10-03 10:47:30 +02:00
UnionArmGuardTests.cs Codec: StandardResolverAllowPrivate's formatter for an id-path type is no claim 2026-10-15 01:23:40 +02:00
UnionParityVectorTests.cs UnionParityVectorTests: a unit arm on a union no list reaches is pinned against the reference; comments no longer call id arms unit arms 2026-10-14 20:31:44 +02:00
VariantTests.cs Tests: a record a type reads but no type declares is read-only on every cache write path 2026-10-03 12:34:58 +02:00
WriteSetTests.cs Tests: a staged record's catalog entry is the writer's encoding, not the file's slice 2026-10-03 12:08:21 +02:00

GameCult.Caching.Tests

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
  • Cult document payloads, registry shape rejections, canonical schema fixtures, and schema drift reports
  • 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).

Run

dotnet test tests\GameCult.Caching.Tests\GameCult.Caching.Tests.csproj