fix
All checks were successful
Docker Build & Deploy / Build Docker Image (push) Successful in 4m27s
Docker Build & Deploy / Deploy to Production (push) Successful in 7s
Docker Build & Deploy / Cleanup Dangling Images (push) Successful in 1s
Docker Build & Deploy / WeChat Notification (push) Successful in 1s
All checks were successful
Docker Build & Deploy / Build Docker Image (push) Successful in 4m27s
Docker Build & Deploy / Deploy to Production (push) Successful in 7s
Docker Build & Deploy / Cleanup Dangling Images (push) Successful in 1s
Docker Build & Deploy / WeChat Notification (push) Successful in 1s
This commit is contained in:
@@ -9,15 +9,13 @@ public class BudgetApplicationTest : BaseApplicationTest
|
||||
{
|
||||
private readonly IBudgetService _budgetService;
|
||||
private readonly IBudgetRepository _budgetRepository;
|
||||
private readonly ILogger<BudgetApplication> _logger;
|
||||
private readonly BudgetApplication _application;
|
||||
|
||||
public BudgetApplicationTest()
|
||||
{
|
||||
_budgetService = Substitute.For<IBudgetService>();
|
||||
_budgetRepository = Substitute.For<IBudgetRepository>();
|
||||
_logger = CreateMockLogger<BudgetApplication>();
|
||||
_application = new BudgetApplication(_budgetService, _budgetRepository, _logger);
|
||||
_application = new BudgetApplication(_budgetService, _budgetRepository);
|
||||
}
|
||||
|
||||
#region GetListAsync Tests
|
||||
|
||||
@@ -12,7 +12,6 @@ public class EmailMessageApplicationTest : BaseApplicationTest
|
||||
private readonly ITransactionRecordRepository _transactionRepository;
|
||||
private readonly IEmailHandleService _emailHandleService;
|
||||
private readonly IEmailSyncService _emailSyncService;
|
||||
private readonly ILogger<EmailMessageApplication> _logger;
|
||||
private readonly EmailMessageApplication _application;
|
||||
|
||||
public EmailMessageApplicationTest()
|
||||
@@ -21,13 +20,11 @@ public class EmailMessageApplicationTest : BaseApplicationTest
|
||||
_transactionRepository = Substitute.For<ITransactionRecordRepository>();
|
||||
_emailHandleService = Substitute.For<IEmailHandleService>();
|
||||
_emailSyncService = Substitute.For<IEmailSyncService>();
|
||||
_logger = CreateMockLogger<EmailMessageApplication>();
|
||||
_application = new EmailMessageApplication(
|
||||
_emailRepository,
|
||||
_transactionRepository,
|
||||
_emailHandleService,
|
||||
_emailSyncService,
|
||||
_logger);
|
||||
_emailSyncService);
|
||||
}
|
||||
|
||||
#region GetListAsync Tests
|
||||
|
||||
@@ -10,17 +10,15 @@ public class JobApplicationTest : BaseApplicationTest
|
||||
{
|
||||
private readonly ISchedulerFactory _schedulerFactory;
|
||||
private readonly IScheduler _scheduler;
|
||||
private readonly ILogger<JobApplication> _logger;
|
||||
private readonly JobApplication _application;
|
||||
|
||||
public JobApplicationTest()
|
||||
{
|
||||
_schedulerFactory = Substitute.For<ISchedulerFactory>();
|
||||
_scheduler = Substitute.For<IScheduler>();
|
||||
_logger = CreateMockLogger<JobApplication>();
|
||||
|
||||
_schedulerFactory.GetScheduler().Returns(_scheduler);
|
||||
_application = new JobApplication(_schedulerFactory, _logger);
|
||||
_application = new JobApplication(_schedulerFactory);
|
||||
}
|
||||
|
||||
#region GetJobsAsync Tests
|
||||
|
||||
@@ -8,14 +8,12 @@ namespace WebApi.Test.Application;
|
||||
public class MessageRecordApplicationTest : BaseApplicationTest
|
||||
{
|
||||
private readonly IMessageService _messageService;
|
||||
private readonly ILogger<MessageRecordApplication> _logger;
|
||||
private readonly MessageRecordApplication _application;
|
||||
|
||||
public MessageRecordApplicationTest()
|
||||
{
|
||||
_messageService = Substitute.For<IMessageService>();
|
||||
_logger = CreateMockLogger<MessageRecordApplication>();
|
||||
_application = new MessageRecordApplication(_messageService, _logger);
|
||||
_application = new MessageRecordApplication(_messageService);
|
||||
}
|
||||
|
||||
[Fact]
|
||||
|
||||
@@ -8,14 +8,12 @@ namespace WebApi.Test.Application;
|
||||
public class NotificationApplicationTest : BaseApplicationTest
|
||||
{
|
||||
private readonly INotificationService _notificationService;
|
||||
private readonly ILogger<NotificationApplication> _logger;
|
||||
private readonly NotificationApplication _application;
|
||||
|
||||
public NotificationApplicationTest()
|
||||
{
|
||||
_notificationService = Substitute.For<INotificationService>();
|
||||
_logger = CreateMockLogger<NotificationApplication>();
|
||||
_application = new NotificationApplication(_notificationService, _logger);
|
||||
_application = new NotificationApplication(_notificationService);
|
||||
}
|
||||
|
||||
#region GetVapidPublicKeyAsync Tests
|
||||
|
||||
@@ -10,15 +10,13 @@ public class TransactionApplicationTest : BaseApplicationTest
|
||||
{
|
||||
private readonly ITransactionRecordRepository _transactionRepository;
|
||||
private readonly ISmartHandleService _smartHandleService;
|
||||
private readonly ILogger<TransactionApplication> _logger;
|
||||
private readonly TransactionApplication _application;
|
||||
|
||||
public TransactionApplicationTest()
|
||||
{
|
||||
_transactionRepository = Substitute.For<ITransactionRecordRepository>();
|
||||
_smartHandleService = Substitute.For<ISmartHandleService>();
|
||||
_logger = CreateMockLogger<TransactionApplication>();
|
||||
_application = new TransactionApplication(_transactionRepository, _smartHandleService, _logger);
|
||||
_application = new TransactionApplication(_transactionRepository, _smartHandleService);
|
||||
}
|
||||
|
||||
#region GetByIdAsync Tests
|
||||
|
||||
@@ -12,7 +12,6 @@ public class TransactionCategoryApplicationTest : BaseApplicationTest
|
||||
private readonly ITransactionRecordRepository _transactionRepository;
|
||||
private readonly IBudgetRepository _budgetRepository;
|
||||
private readonly ISmartHandleService _smartHandleService;
|
||||
private readonly ILogger<TransactionCategoryApplication> _logger;
|
||||
private readonly TransactionCategoryApplication _application;
|
||||
|
||||
public TransactionCategoryApplicationTest()
|
||||
@@ -21,13 +20,11 @@ public class TransactionCategoryApplicationTest : BaseApplicationTest
|
||||
_transactionRepository = Substitute.For<ITransactionRecordRepository>();
|
||||
_budgetRepository = Substitute.For<IBudgetRepository>();
|
||||
_smartHandleService = Substitute.For<ISmartHandleService>();
|
||||
_logger = CreateMockLogger<TransactionCategoryApplication>();
|
||||
_application = new TransactionCategoryApplication(
|
||||
_categoryRepository,
|
||||
_transactionRepository,
|
||||
_budgetRepository,
|
||||
_smartHandleService,
|
||||
_logger);
|
||||
_smartHandleService);
|
||||
}
|
||||
|
||||
#region GetListAsync Tests
|
||||
|
||||
@@ -10,15 +10,13 @@ public class TransactionPeriodicApplicationTest : BaseApplicationTest
|
||||
{
|
||||
private readonly ITransactionPeriodicRepository _periodicRepository;
|
||||
private readonly ITransactionPeriodicService _periodicService;
|
||||
private readonly ILogger<TransactionPeriodicApplication> _logger;
|
||||
private readonly TransactionPeriodicApplication _application;
|
||||
|
||||
public TransactionPeriodicApplicationTest()
|
||||
{
|
||||
_periodicRepository = Substitute.For<ITransactionPeriodicRepository>();
|
||||
_periodicService = Substitute.For<ITransactionPeriodicService>();
|
||||
_logger = CreateMockLogger<TransactionPeriodicApplication>();
|
||||
_application = new TransactionPeriodicApplication(_periodicRepository, _periodicService, _logger);
|
||||
_application = new TransactionPeriodicApplication(_periodicRepository, _periodicService);
|
||||
}
|
||||
|
||||
#region GetListAsync Tests
|
||||
|
||||
@@ -10,15 +10,13 @@ public class TransactionStatisticsApplicationTest : BaseApplicationTest
|
||||
{
|
||||
private readonly ITransactionStatisticsService _statisticsService;
|
||||
private readonly IConfigService _configService;
|
||||
private readonly ILogger<TransactionStatisticsApplication> _logger;
|
||||
private readonly TransactionStatisticsApplication _application;
|
||||
|
||||
public TransactionStatisticsApplicationTest()
|
||||
{
|
||||
_statisticsService = Substitute.For<ITransactionStatisticsService>();
|
||||
_configService = Substitute.For<IConfigService>();
|
||||
_logger = CreateMockLogger<TransactionStatisticsApplication>();
|
||||
_application = new TransactionStatisticsApplication(_statisticsService, _configService, _logger);
|
||||
_application = new TransactionStatisticsApplication(_statisticsService, _configService);
|
||||
}
|
||||
|
||||
#region GetBalanceStatisticsAsync Tests
|
||||
|
||||
Reference in New Issue
Block a user