Esempio n. 1
0
        public InningSpecs()
        {
            this._teamA = A.Dummy <Team>();
            this._teamB = A.Dummy <Team>();

            this._inning = InningFakes.Data.GetInning(this._teamA, this._teamB);

            this._striker    = this._teamA.Players.Batsmen.First();
            this._nonStriker = this._teamA.Players.Batsmen.Last();
            this._bowler     = this._teamB.Players.Bowlers.Last();
        }
Esempio n. 2
0
        public void UpdateCurrentInningShouldSetInning()
        {
            //Act
            this._score.UpdateCurrentInning();

            var expectedInning = new Inning(
                this._score.TeamA,
                this._score.TeamB,
                20);

            //Arrange
            this._score.CurrentInning !.BattingTeam.Id
            .Should()
            .Be(expectedInning.BattingTeam.Id);

            this._score.CurrentInning !.BowlingTeam.Id
            .Should()
            .Be(expectedInning.BowlingTeam.Id);
        }