Scanner not merging with series that has LocalizedName match (#950)
* When performing a scan, series should group if they share the same localized name as a pre-existing series. * Fixed a bug where a series with a different name and localized name weren't merging with a different set of files with the same naming as localized name.
This commit is contained in:
parent
2434e96fe9
commit
ce3bd92244
4 changed files with 52 additions and 6 deletions
|
|
@ -102,6 +102,41 @@ public class SeriesHelperTests
|
|||
NormalizedName = API.Parser.Parser.Normalize("SomethingRandom")
|
||||
}));
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void FindSeries_ShouldFind_UsingLocalizedName()
|
||||
{
|
||||
var series = DbFactory.Series("Darker than Black");
|
||||
series.LocalizedName = "Something Random";
|
||||
series.Format = MangaFormat.Image;
|
||||
Assert.True(SeriesHelper.FindSeries(series, new ParsedSeries()
|
||||
{
|
||||
Format = MangaFormat.Image,
|
||||
Name = "Something Random",
|
||||
NormalizedName = API.Parser.Parser.Normalize("Something Random")
|
||||
}));
|
||||
|
||||
Assert.True(SeriesHelper.FindSeries(series, new ParsedSeries()
|
||||
{
|
||||
Format = MangaFormat.Image,
|
||||
Name = "Something Random".ToLower(),
|
||||
NormalizedName = API.Parser.Parser.Normalize("Something Random")
|
||||
}));
|
||||
|
||||
Assert.True(SeriesHelper.FindSeries(series, new ParsedSeries()
|
||||
{
|
||||
Format = MangaFormat.Image,
|
||||
Name = "Something Random".ToUpper(),
|
||||
NormalizedName = API.Parser.Parser.Normalize("Something Random")
|
||||
}));
|
||||
|
||||
Assert.True(SeriesHelper.FindSeries(series, new ParsedSeries()
|
||||
{
|
||||
Format = MangaFormat.Image,
|
||||
Name = "SomethingRandom".ToUpper(),
|
||||
NormalizedName = API.Parser.Parser.Normalize("SomethingRandom")
|
||||
}));
|
||||
}
|
||||
#endregion
|
||||
|
||||
[Fact]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue