Exemple #1
0
 private IDice CreateDice(int result)
 {
     var dice = new Mock<IDice>();
     var diceroll = new DiceRoll(new int[] { result });
     dice.Setup(d => d.Current).Returns(diceroll);
     return dice.Object;
 }
Exemple #2
0
 public void Roll()
 {
     Current = new DiceRoll(dice.Select(d => d.Throw()));
 }