public void HomeTest() { Club home = new Club("France"); Club away = new Club("Allemagne"); int homeGoal = 3; int awayGoal = 3; Match match = new Match(home, away, homeGoal, awayGoal); Assert.IsNotNull(home); }
public void IsAwayForfaitTest() { Club home = new Club("France"); Club away = new Club("Allemagne"); int homeGoal = 3; int awayGoal = -1; Match match = new Match(home, away, homeGoal, awayGoal); Assert.IsTrue(match.IsAwayForfait); }
public void MatchConstructorTest() { Club home = new Club("France"); Club away = new Club("Allemagne"); int homeGoal = 0; int awayGoal = 0; Match match = new Match(home,away,homeGoal,awayGoal); Assert.IsNotNull(match); }
public void Register(Match m) { EntryFromClub(m.Home).Points.Increment(system.GetPointsFromMatch(m, true)); EntryFromClub(m.Away).Points.Increment(system.GetPointsFromMatch(m, false)); Array.Sort(entries); }
public ITotal GetPointsFromMatch(Match m, bool home) { return this.InitialPoints; }
public TotalMock(Match m, bool home) { this.points = m.GetGoals(home) - m.GetGoals(!home); }
public override ITotal GetPointsFromMatch(Match m, bool isHome) { return new TotalMock(m, isHome); }