Created Windows Service

This commit is contained in:
Chase Tucker
2024-04-03 12:05:44 -07:00
parent 35690df362
commit 794b616293
14 changed files with 247 additions and 38 deletions

View File

@ -0,0 +1,29 @@
using FabApprovalWorkerService.Services;
using Microsoft.Extensions.Logging;
using Moq;
namespace FabApprovalWorkerServiceTests;
public class TrainingServiceTests {
private Mock<ILogger<TrainingService>> _mockLogger;
private Mock<IDalService> _mockDalService;
private TrainingService _trainingService;
[SetUp]
public void Setup() {
_mockLogger = new Mock<ILogger<TrainingService>>();
_mockDalService = new Mock<IDalService>();
}
[Test]
public void TrainingServiceWithNullLoggerShouldThrowException() {
Assert.Throws<ArgumentNullException>(() => new TrainingService(null, _mockDalService.Object));
}
[Test]
public void TrainingServiceWithNullDalServiceShouldThrowException() {
Assert.Throws<ArgumentNullException>(() => new TrainingService(_mockLogger.Object, null));
}
}