-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
a0eee1d
commit b7a7e99
Showing
1 changed file
with
64 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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); | ||
} | ||
|
||
} | ||
} |