mirror of
https://github.com/volodymyrsmirnov/MalwareMultiScan.git
synced 2025-08-25 22:01:16 +00:00
unit tests for API (99% coverage)
This commit is contained in:
@@ -1,5 +1,7 @@
|
||||
using System.Diagnostics.CodeAnalysis;
|
||||
using MalwareMultiScan.Api.Extensions;
|
||||
using MalwareMultiScan.Api.Services;
|
||||
using MalwareMultiScan.Api.Services.Implementations;
|
||||
using MalwareMultiScan.Api.Services.Interfaces;
|
||||
using Microsoft.AspNetCore.Builder;
|
||||
using Microsoft.AspNetCore.Server.Kestrel.Core;
|
||||
using Microsoft.Extensions.Configuration;
|
||||
@@ -7,7 +9,8 @@ using Microsoft.Extensions.DependencyInjection;
|
||||
|
||||
namespace MalwareMultiScan.Api
|
||||
{
|
||||
public class Startup
|
||||
[ExcludeFromCodeCoverage]
|
||||
internal class Startup
|
||||
{
|
||||
private readonly IConfiguration _configuration;
|
||||
|
||||
@@ -28,8 +31,8 @@ namespace MalwareMultiScan.Api
|
||||
services.AddMongoDb(_configuration);
|
||||
services.AddRabbitMq(_configuration);
|
||||
|
||||
services.AddSingleton<ScanBackendService>();
|
||||
services.AddSingleton<ScanResultService>();
|
||||
services.AddSingleton<IScanBackendService, ScanBackendService>();
|
||||
services.AddSingleton<IScanResultService, ScanResultService>();
|
||||
|
||||
services.AddControllers();
|
||||
|
||||
|
Reference in New Issue
Block a user