CachelessSingleFileTests: the second cache's record is keyed by its name's hash, so assert the file's three records, not the key "c"
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
parent
e38925e249
commit
e06d5a2e8c
1 changed files with 3 additions and 1 deletions
|
|
@ -323,7 +323,9 @@ namespace GameCult.Caching.Tests
|
|||
Assert.That(store.Attached, Is.SameAs(registry2), "the call's end did not detach the second cache's registry");
|
||||
await cache2.AddAsync(new IdDeck { Name = "c" });
|
||||
Assert.DoesNotThrow(() => cache2.FlushAllBackingStores());
|
||||
Assert.That(new SingleFileMessagePackBackingStore(_path).ReadStoreSnapshot()!.Records.Select(record => record.Key), Is.SupersetOf(new[] { "a", "first", "c" }));
|
||||
var keys = new SingleFileMessagePackBackingStore(_path).ReadStoreSnapshot()!.Records.Select(record => record.Key).ToArray();
|
||||
Assert.That(keys, Has.Length.EqualTo(3), "the seed, the call's record and the cache's record");
|
||||
Assert.That(keys, Does.Contain("a").And.Contain("first"));
|
||||
}
|
||||
|
||||
// The attach waits for a call that is already inside the store, wherever in the call it is: here inside the payload encoding,
|
||||
|
|
|
|||
Loading…
Reference in a new issue