Added common language enum. Fixed "romaji" spelling. More UI updates.
This commit is contained in:
@@ -1,7 +1,9 @@
|
||||
using MangaReader.Core.Data;
|
||||
using MangaReader.Core.Common;
|
||||
using MangaReader.Core.Data;
|
||||
using MangaReader.Core.Metadata;
|
||||
using MangaReader.Core.Pipeline;
|
||||
using MangaReader.Tests.Utilities;
|
||||
using Shouldly;
|
||||
|
||||
namespace MangaReader.Tests.Pipeline;
|
||||
|
||||
@@ -21,7 +23,7 @@ public class MangaPipelineTests(TestDbContextFactory factory) : IClassFixture<Te
|
||||
new()
|
||||
{
|
||||
Title = "Hagane no Renkinjutsushi",
|
||||
Language = SourceMangaLanguage.Romanji
|
||||
Language = Language.Romaji
|
||||
}
|
||||
],
|
||||
Genres = ["Action", "Adventure"],
|
||||
@@ -40,14 +42,15 @@ public class MangaPipelineTests(TestDbContextFactory factory) : IClassFixture<Te
|
||||
MangaPipelineRequest request = new()
|
||||
{
|
||||
SourceName = "MySource",
|
||||
SourceUrl = "https://wwww.mymangasource.org/my-manga",
|
||||
SourceManga = sourceManga
|
||||
};
|
||||
|
||||
await pipeline.RunAsync(request);
|
||||
|
||||
Assert.Single(context.Mangas);
|
||||
Assert.Single(context.MangaTitles);
|
||||
Assert.Equal(2, context.Genres.Count());
|
||||
Assert.Single(context.MangaChapters);
|
||||
context.Mangas.ShouldHaveSingleItem();
|
||||
context.MangaTitles.ShouldHaveSingleItem();
|
||||
context.Genres.Count().ShouldBe(2);
|
||||
context.MangaChapters.ShouldHaveSingleItem();
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user