Release 0.2.5: harden proxy and streamline metadata fetching
Remove obsolete rule formats, batch SQLite work, preserve artwork source URLs, and coordinate refresh workers with maintenance. Add regression coverage and document backup format changes.
This commit is contained in:
1 parent
7eb62b156e
commit
e36775f1a3
49 files changed
+2126
-1813
No files matched your search
@@ -13,6 +13,22 @@ public sealed class ItemsProxyTransformerResolutionTests
|
||||
private const string OriginalAction = "Original";
|
||||
private const string LanguagePrefix = "Language:";
|
||||
|
||||
[Fact]
|
||||
public void TraceUsesStoredOriginalTranslationWhenOriginalTitleIsEmpty()
|
||||
{
|
||||
var facts = Facts(originalTitle: "", originalLanguage: "fi");
|
||||
var translations = TextTranslations((OriginalAction, TitleField, "Alkuperainen nimi"));
|
||||
var attempts = new List<ItemsProxyResolutionAttempt>();
|
||||
var normal = ItemsProxyTransformer.ResolveField(TitleField, [OriginalAction], facts, translations);
|
||||
var traced = ItemsProxyTransformer.ResolveField(TitleField, [OriginalAction], facts, translations, attempts.Add);
|
||||
Assert.Equal(normal, traced);
|
||||
Assert.Equal("fi", traced.Language);
|
||||
var chosen = Assert.Single(attempts);
|
||||
Assert.True(chosen.Chosen);
|
||||
Assert.Equal("Original/title", chosen.LookupKey);
|
||||
Assert.Equal(traced.Value, chosen.Value);
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void ResolveFieldUsesFirstLanguageWithData()
|
||||
{
|
||||
|
||||
Reference in new issue
Block a user