Esempio n. 1
0
        private void CanGetAllMarketsByEventId()
        {
            var newEvent = Common.CreateAndSaveMockEvent(EventController);

            Common.CreateAndSaveMockMarket(newEvent.Id, "Team 1 Wins", 0.8m, MarketController);
            Common.CreateAndSaveMockMarket(newEvent.Id, "Team 2 Wins", 0.6m, MarketController);
            Common.CreateAndSaveMockMarket(newEvent.Id, "Draw", 0.1m, MarketController);

            var persistedMarkets = MarketController.GetByEventId(newEvent.Id);

            Assert.Equal(3, persistedMarkets.Count);
        }