public FrequencyRepository( IFrequencyAdapter adapter, IDbContextFactory dbContextFactory) { _adapter = adapter; _context = (WebFrequenciesDbContext)dbContextFactory.GetContext(); }
public FetchRepository( IFrequencyAdapter frequencyAdapter, WebFrequenciesDbContext context) { _frequencyAdapter = frequencyAdapter; _context = context; }
static FrequencyRepositorySliceTest() { _context = TestDbContextUtils.NewTestContext; _context.Frequencies.Add(new FrequencyEntity { @EncryptedWord = "encrypted1", Count = 15 }); _context.Frequencies.Add(new FrequencyEntity { @EncryptedWord = "encrypted2", Count = 20 }); _context.SaveChanges(); _contextFactoryMock.Setup(x => x.GetContext()).Returns(_context); }
public FetchRepositorySliceTest() { _context = TestDbContextUtils.NewTestContext; _encryptionServiceMock = new Mock <IEncryptionService>(); _fetchMock = FetchFixtures.StanfordCoreNLPWithRandomUrl; }