Skip to content

Commit

Permalink
test: Camada Application.
Browse files Browse the repository at this point in the history
  • Loading branch information
MatheusKoszudikass committed Sep 11, 2024
1 parent a0eee1d commit b7a7e99
Showing 1 changed file with 64 additions and 0 deletions.
64 changes: 64 additions & 0 deletions Blazing.Test/Application/ApplicationFixtureTest.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using AutoMapper;
using Blazing.Application.Mappings;
using Blazing.Application.Services;
using Blazing.Domain.Entities;
using Blazing.Domain.Interfaces.Services;
using Blazing.Domain.Services;
using BlazingPizzaTest.Data;
using Moq;

namespace Blazing.Test.Application
{
public class ApplicationFixtureTest
{
public PeopleOfData PeopleOfData { get; } = new();

public IMapper Mapper { get; }

//Products
public ProductDomainService ProductDomainService { get; }
public ProductAppService ProductAppService { get; }


//Categories
public CategoryDomainService CategoryDomainService { get; }
public CategoryAppService CategoryAppService { get; }

//Users
public UserDomainService UserDomainService { get; }
public UserAppService UserAppService { get; }


public ApplicationFixtureTest()
{
var config = new MapperConfiguration(cfg =>
{
cfg.AddProfile<BlazingProfile>();
}).CreateMapper();

Mapper = config;

//Products
ProductDomainService = new ProductDomainService();

ProductAppService = new ProductAppService(Mapper,ProductDomainService);


//Categories
CategoryDomainService = new CategoryDomainService();

CategoryAppService = new CategoryAppService(CategoryDomainService, Mapper);

//Users
UserDomainService = new UserDomainService();

UserAppService = new UserAppService(Mapper, UserDomainService);
}

}
}

0 comments on commit b7a7e99

Please sign in to comment.