public void Rolling0DiceReturnsEmptyDiceResult()
        {
            var pouch = new DicePouch();

            var results = pouch.Roll(0);

            Assert.IsEmpty(results.Summary());
        }
        public void Rolling_DiceReturnsDiceResultWith_Dice(int count)
        {
            var pouch = new DicePouch();

            var results = pouch.Roll(count);

            Assert.AreEqual(count, results.Summary().Count());
        }
        public void ShouldHaveAllNumbersAfter36Rolls()
        {
            var pouch = new DicePouch();

            var results = pouch.Roll(36);

            CollectionAssert.Contains(results.Summary(), 1);
            CollectionAssert.Contains(results.Summary(), 2);
            CollectionAssert.Contains(results.Summary(), 3);
            CollectionAssert.Contains(results.Summary(), 4);
            CollectionAssert.Contains(results.Summary(), 5);
            CollectionAssert.Contains(results.Summary(), 6);
        }
Example #4
0
        public Game(IPlayerBoardFactory playerBoardFactory)
        {
            _playerBoardFactory = playerBoardFactory;

            _dicePouch = new DicePouch();
        }