public CarRepositoryTests() { connectionService = new Mock <IConnection>(); var db = new InMemoryDatabase(); db.Insert(cars); connectionService.Setup(c => c.GetConnection(configuration)).Returns(db.OpenConnection()); carGateway = new CarRepository(connectionService.Object, configuration); }
public CarUseCase(ICarGateway carGateway) { _carGateway = carGateway; }