Exemple #1
0
        public void RepoLeagueTestsUpdateMaxPlayers()
        {
            List <League> l = new List <League>
            {
                new League {
                    LeagueID = 0, GameTitle = "Halo", MaxPlayers = 2
                }
            };

            _leagueSet.Object.AddRange(l);
            ConnectMocksToDataStore(l);
            bool          result   = _repo.UpdateLeagueMaxPlayers(0, 4);
            List <League> actual   = _repo.GetAllLeagues();
            List <League> expected = new List <League>
            {
                new League {
                    LeagueID = 0, GameTitle = "Halo", MaxPlayers = 4
                }
            };

            Assert.IsTrue(result);
            CollectionAssert.AreEqual(expected, actual);
        }