public void SetUp() { _banlistService = Substitute.For <IBanlistService>(); _logger = Substitute.For <ILogger <BanlistDataConsumerHandler> >(); _sut = new BanlistDataConsumerHandler(_banlistService, _logger); }
/// <summary> /// Initializes a new instance of the <see cref="DecklistService"/> class. /// </summary> /// <param name="db">The database.</param> /// <param name="banlistService">The banlist service.</param> /// <exception cref="ArgumentNullException"> /// db /// or /// banlistService /// </exception> public DecklistService( YgoProAnalyticsDatabase db, IBanlistService banlistService) { _db = db ?? throw new ArgumentNullException(nameof(db)); _banlistService = banlistService ?? throw new ArgumentNullException(nameof(banlistService)); }
public void SetUp() { _db = new YgoProAnalyticsDatabase(SqlInMemoryHelper.SqlLiteOptions <YgoProAnalyticsDatabase>()); _db.Database.EnsureCreated(); _cacheMock = new Mock <IMemoryCache>(); _configMock = new Mock <IAdminConfig>(); _banlistService = new BanlistService(_db, _cacheMock.Object, _configMock.Object); }
public BanlistController( IBanlistService banlistService, IBanlistBrowserQueryParamsValidator validator, INumberOfResultsHelper numberOfResultsHelper, IBanlistToBanlistDTOConverter banlistToDtoConverter) { _banlistService = banlistService ?? throw new ArgumentNullException(nameof(banlistService)); _validator = validator ?? throw new ArgumentNullException(nameof(validator)); _numberOfResultsHelper = numberOfResultsHelper ?? throw new ArgumentNullException(nameof(numberOfResultsHelper)); _banlistToDtoConverter = banlistToDtoConverter ?? throw new ArgumentNullException(nameof(banlistToDtoConverter)); }
public void SetUp() { _banlistService = Substitute.For <IBanlistService>(); var config = new MapperConfiguration ( cfg => { cfg.AddProfile(new CardProfile()); } ); var mapper = config.CreateMapper(); _sut = new LatestBanlistQueryHandler(_banlistService, mapper); }
public YgoProAnalysisBasedOnDataFromYgoProServer( IDuelLogNameAnalyzer duelLogNameAnalyzer, YgoProAnalyticsDatabase db, IArchetypeAndDecklistAnalyzer archetypeAndDecklistAnalyzer, IYDKToDecklistConverter yDKToDecklistConverter, IBanlistService banlistService, IDecklistService decklistService) { _duelLogNameAnalyzer = duelLogNameAnalyzer; _db = db; _archetypeAndDecklistAnalyzer = archetypeAndDecklistAnalyzer; _yDKToDecklistConverter = yDKToDecklistConverter; _banlistService = banlistService; _decklistService = decklistService; }
public MostRecentBanlistsQueryHandler(IBanlistService banlistService) { _banlistService = banlistService; }
public BanlistDataConsumerHandler(IBanlistService banlistService, ILogger <BanlistDataConsumerHandler> logger) { _banlistService = banlistService; _logger = logger; }
public LatestBanlistQueryHandler(IBanlistService banlistService, IMapper mapper) { _banlistService = banlistService; _mapper = mapper; }
public void SetUp() { _banlistService = Substitute.For <IBanlistService>(); _sut = new MostRecentBanlistsQueryHandler(_banlistService); }
public YugiohBanlistService(IFormatService formatService, IBanlistService banlistService, IBanlistCardsService banlistCardsService) { _formatService = formatService; _banlistService = banlistService; _banlistCardsService = banlistCardsService; }