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);
        }
Exemplo n.º 2
0
 public CarUseCase(ICarGateway carGateway)
 {
     _carGateway = carGateway;
 }