public DemoXTests() { var mock = new Mock <IRaceContext>(); mock.Setup(x => x.CustomerRepository).Returns(new FakeRepository <Customer>(customers)); mock.Setup(x => x.BetRepository).Returns(new FakeRepository <Bet>(bets)); mock.Setup(x => x.RaceRepository).Returns(new FakeRepository <Race>(races)); context = mock.Object; raceBusiness = new RaceBusiness(context); }
public RaceBusiness(IRaceContext context) { this.context = context; }