chore: upgrade to ASP.NET Core 8

This commit is contained in:
Jean Gatto
2023-11-19 16:08:47 -03:00
parent 887d2a76ac
commit c2c985e4ba
45 changed files with 164 additions and 270 deletions
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net7.0</TargetFramework>
<TargetFramework>net8.0</TargetFramework>
<IsPackable>false</IsPackable>
<IsTestProject>true</IsTestProject>
</PropertyGroup>
@@ -20,13 +20,11 @@ using Xunit.Categories;
namespace Shop.UnitTests.Application.Customer.Handlers;
[UnitTest]
public class CreateCustomerCommandHandlerTests : IClassFixture<EfSqliteFixture>
public class CreateCustomerCommandHandlerTests(EfSqliteFixture fixture) : IClassFixture<EfSqliteFixture>
{
private readonly EfSqliteFixture _fixture;
private readonly EfSqliteFixture _fixture = fixture;
private readonly CreateCustomerCommandValidator _validator = new();
public CreateCustomerCommandHandlerTests(EfSqliteFixture fixture) => _fixture = fixture;
[Fact]
public async Task Add_ValidCommand_ShouldReturnsSuccessResult()
{
@@ -20,13 +20,11 @@ using Xunit.Categories;
namespace Shop.UnitTests.Application.Customer.Handlers;
[UnitTest]
public class DeleteCustomerCommandHandlerTests : IClassFixture<EfSqliteFixture>
public class DeleteCustomerCommandHandlerTests(EfSqliteFixture fixture) : IClassFixture<EfSqliteFixture>
{
private readonly EfSqliteFixture _fixture;
private readonly EfSqliteFixture _fixture = fixture;
private readonly DeleteCustomerCommandValidator _validator = new();
public DeleteCustomerCommandHandlerTests(EfSqliteFixture fixture) => _fixture = fixture;
[Fact]
public async Task Delete_ValidCustomerId_ShouldReturnsSuccessResult()
{
@@ -19,13 +19,11 @@ using Xunit.Categories;
namespace Shop.UnitTests.Application.Customer.Handlers;
[UnitTest]
public class UpdateCustomerCommandHandlerTest : IClassFixture<EfSqliteFixture>
public class UpdateCustomerCommandHandlerTest(EfSqliteFixture fixture) : IClassFixture<EfSqliteFixture>
{
private readonly EfSqliteFixture _fixture;
private readonly EfSqliteFixture _fixture = fixture;
private readonly UpdateCustomerCommandValidator _validator = new();
public UpdateCustomerCommandHandlerTest(EfSqliteFixture fixture) => _fixture = fixture;
[Fact]
public async Task Update_ValidCommand_ShouldReturnsSuccessResult()
{
+1 -1
View File
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net7.0</TargetFramework>
<TargetFramework>net8.0</TargetFramework>
<IsPackable>false</IsPackable>
<IsTestProject>true</IsTestProject>
<SonarQubeTestProject>True</SonarQubeTestProject>