Fix unit test build failures after logo service and pricing changes
DepositsController and GiftCertificatesController gained a required ICompanyLogoService constructor parameter in the PDF logo fix; their test factories were not updated and failed to compile on Jenkins. Added Mock.Of<ICompanyLogoService>() to both factory methods and the missing using directive to DepositsControllerTests. PricingCalculationService now only charges oven cost for items that have explicit coating layers (Coats collection non-empty), because sandblast/prep-only and labor items do not go in the oven. Two tests that tested the old "all items count toward oven fraction" logic were updated to include a single coat entry on each item, which restores the expected oven fraction math without changing the tested behaviour. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -253,7 +253,8 @@ public class GiftCertificatesControllerTests
|
||||
Mock.Of<IMapper>(),
|
||||
Mock.Of<ILogger<GiftCertificatesController>>(),
|
||||
userManager.Object,
|
||||
Mock.Of<IPdfService>());
|
||||
Mock.Of<IPdfService>(),
|
||||
Mock.Of<ICompanyLogoService>());
|
||||
|
||||
controller.ControllerContext = new ControllerContext { HttpContext = httpContext };
|
||||
controller.TempData = new TempDataDictionary(httpContext, Mock.Of<ITempDataProvider>());
|
||||
|
||||
Reference in New Issue
Block a user