Test: the directory store's wrong-format refusal is the typed exception naming the manifest
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
parent
51967aff68
commit
bcf6ce5cf6
1 changed files with 2 additions and 1 deletions
|
|
@ -213,7 +213,8 @@ namespace GameCult.Caching.Tests
|
|||
using var cache = new CultCache();
|
||||
|
||||
Assert.That(() => cache.AddBackingStore(new DirectoryMessagePackBackingStore(manifest)),
|
||||
Throws.TypeOf<InvalidOperationException>().With.Message.Contains(formatVersion));
|
||||
Throws.TypeOf<CultStoreUnreadableException>().With.Message.Contains(formatVersion)
|
||||
.And.Property(nameof(CultStoreUnreadableException.Path)).EqualTo(manifest));
|
||||
Assert.That(cache.BackingStores, Is.Empty);
|
||||
Assert.That(File.ReadAllBytes(manifest), Is.EqualTo(bytes));
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue