Exemple #1
0
        public async Task GetActiveRacesTest()
        {
            var race = (await RaceDao.FindAllAsync()).First();

            race.RaceStateId = 2;
            await RaceDao.UpdateAsync(race);

            Assert.AreEqual(1, (await RaceDao.GetActiveRaces()).Count());
        }
Exemple #2
0
        public async Task GetActiveRaceByIdTest()
        {
            var race = (await RaceDao.FindAllAsync()).First();

            race.RaceStateId = 2;
            await RaceDao.UpdateAsync(race);

            Assert.NotNull(await RaceDao.GetActiveRaceById(race.Id));
        }
Exemple #3
0
        public async Task UpdateTest()
        {
            var race = (await RaceDao.FindAllAsync()).First();

            race.RaceDescription = "Test123";
            await RaceDao.UpdateAsync(race);

            Assert.AreEqual(race.RaceDescription, (await RaceDao.FindByIdAsync(race.Id))?.RaceDescription);
        }