public ItemImportServiceTests() { var options = new DbContextOptionsBuilder <ShoppingCartContext>() .UseInMemoryDatabase(databaseName: Guid.NewGuid().ToString()) .Options; _context = new ShoppingCartContext(options); this._testClass = new ItemImportService(_context); }
public UserRepositoryTests() { var options = new DbContextOptionsBuilder <ShoppingCartContext>() .UseInMemoryDatabase(databaseName: Guid.NewGuid().ToString()) .Options; _context = new ShoppingCartContext(options); this._testClass = new UserRepository(_context); var importService = new ItemImportService(_context); importService.ImportItems().Wait(); }