Updated various parts of scanning and ingestion, either for bug fixes, or for enhancements.
All checks were successful
ci / build-test (push) Successful in 2m22s
ci / publish-image (push) Has been skipped

This commit is contained in:
2026-03-01 22:07:20 -05:00
parent 704a6fc433
commit 83655f13e9
20 changed files with 555 additions and 90 deletions

View File

@@ -0,0 +1,39 @@
using JSMR.Application.Scanning.Contracts;
using JSMR.Domain.Enums;
namespace JSMR.Tests.Unit;
internal static class DLSiteWorkTestFactory
{
private static int _counter = 0;
public static DLSiteWork Create(DateOnly? expectedDate = null, DateOnly? salesDate = null)
{
int id = Interlocked.Increment(ref _counter);
return new DLSiteWork
{
ProductName = $"Test Product {id}",
ProductId = $"RJ_TEST_{id:00000000}",
Maker = "Test Maker",
MakerId = "RG_TEST",
ImageUrl = "//img.dlsite.jp/test_main.jpg",
SmallImageUrl = "//img.dlsite.jp/test_sam.jpg",
AgeRating = AgeRating.AllAges,
// Relevant fields for these tests:
ExpectedDate = expectedDate,
SalesDate = salesDate,
// The rest can be safe defaults:
Downloads = 0,
StarRating = null,
Votes = null,
Description = null,
Genres = [],
Tags = [],
Creators = [],
HasTrial = false
};
}
}