public void TestThreeOfAKind_MultiUseCategory_ThrowsException()
 {
     DieSet dieSet = new DieSet(1, 1, 2, 3, 1);
     ScoringCategory threeKind = new ThreeOfAKindCategory();
     int score = threeKind.Score(dieSet.getCount());
     score = threeKind.Score(dieSet.getCount());
 }
 public void TestFourOfAKindAlt_MultiUseCategory_ThrowsException()
 {
     DieSet dieSet = new DieSet(1, 1, 2, 3, 1);
     ScoringCategory fourKindAlt = new FourOfAKindAltCategory();
     int score = fourKindAlt.Score(dieSet.getCount());
     score = fourKindAlt.Score(dieSet.getCount());
 }
 public void TestYahtzee_MultiUseCategory_ThrowsException()
 {
     DieSet dieSet = new DieSet(1, 1, 2, 3, 1);
     ScoringCategory yahtzee = new YahtzeeCategory();
     int score = yahtzee.Score(dieSet.getCount());
     score = yahtzee.Score(dieSet.getCount());
 }
 public void TestTwoPairs_MultiUseCategory_ThrowsException()
 {
     DieSet dieSet = new DieSet(1, 1, 2, 3, 1);
     ScoringCategory twoPairs = new TwoPairsCategory();
     int score = twoPairs.Score(dieSet.getCount());
     score = twoPairs.Score(dieSet.getCount());
 }
 public void TestLittleStraight_MultiUseCategory_ThrowsException()
 {
     DieSet dieSet = new DieSet(1, 1, 2, 3, 1);
     ScoringCategory littleStraight = new LittleStraightCategory();
     int score = littleStraight.Score(dieSet.getCount());
     score = littleStraight.Score(dieSet.getCount());
 }
 public void TestFullHouseAlt_MultiUseCategory_ThrowsException()
 {
     DieSet dieSet = new DieSet(1, 1, 2, 3, 1);
     ScoringCategory fullHouseAlt = new FullHouseAltCategory();
     int score = fullHouseAlt.Score(dieSet.getCount());
     score = fullHouseAlt.Score(dieSet.getCount());
 }
Exemplo n.º 7
0
 public void TestFives_MultiUseCategory_ThrowsException()
 {
     DieSet dieSet = new DieSet(1, 1, 2, 3, 1);
     ScoringCategory fives = new UpperCategory("Fives", 5);
     int score = fives.Score(dieSet.getCount());
     score = fives.Score(dieSet.getCount());
 }
 public void TestOnePair_MultiUseCategory_ThrowsException()
 {
     DieSet dieSet = new DieSet(1, 1, 2, 3, 1);
     ScoringCategory onePair = new OnePairCategory();
     int score = onePair.Score(dieSet.getCount());
     score = onePair.Score(dieSet.getCount());
 }
Exemplo n.º 9
0
 public void TestTwos_MultiUseCategory_ThrowsException()
 {
     DieSet dieSet = new DieSet(1, 1, 2, 3, 1);
     ScoringCategory twos = new UpperCategory("Twos", 2);
     int score = twos.Score(dieSet.getCount());
     score = twos.Score(dieSet.getCount());
 }
 public void TestLargeStraightAlt()
 {
     DieSet die = new DieSet(3, 2, 6, 5, 4);
     ScoringCategory largeStraightAlt = new LargeStraightAltCategory();
     int score = largeStraightAlt.CalculateScoreForRoll(die.getCount());
     Assert.IsTrue(score == 20);
 }
 public void TestFullHouseAltJoker()
 {
     DieSet die = new DieSet(1, 1, 1, 1, 1);
     ScoringCategory fullHouseAlt = new FullHouseAltCategory();
     int score = fullHouseAlt.CalculateScoreForRoll(die.getCount(), true);
     Assert.IsTrue(score == 5);
 }
Exemplo n.º 12
0
 public void TestFullHouseNoScore()
 {
     DieSet die = new DieSet(1, 2, 3, 4, 5);
     ScoringCategory fullHouse = new FullHouseCategory();
     int score = fullHouse.CalculateScoreForRoll(die.getCount());
     Assert.IsTrue(score == 0);
 }
Exemplo n.º 13
0
 public void TestOnesSomeOnes()
 {
     DieSet dieSet = new DieSet(1, 1, 2, 3, 1);
     ScoringCategory ones = new UpperCategory("Ones", 1);
     int score = ones.CalculateScoreForRoll(dieSet.getCount());
     Assert.IsTrue(score == 3);
 }
 public void TestLargeStraightNoScore()
 {
     DieSet die = new DieSet(1, 2, 3, 4, 6);
     ScoringCategory largeStraight = new LargeStraightCategory();
     int score = largeStraight.CalculateScoreForRoll(die.getCount());
     Assert.IsTrue(score == 0);
 }
 public void TestLittleStraightNoScore()
 {
     DieSet die = new DieSet(6, 2, 3, 4, 5);
     ScoringCategory littleStraight = new LittleStraightCategory();
     int score = littleStraight.CalculateScoreForRoll(die.getCount());
     Assert.AreEqual(0, score);
 }
 public void TestLittleStraight()
 {
     DieSet die = new DieSet(1, 4, 3, 2, 5);
     ScoringCategory littleStraight = new LittleStraightCategory();
     int score = littleStraight.CalculateScoreForRoll(die.getCount());
     Assert.IsTrue(score == 30);
 }
Exemplo n.º 17
0
 public void TestFivesSomeFives()
 {
     DieSet dieSet = new DieSet(1, 2, 3, 4, 5);
     ScoringCategory fives = new UpperCategory("Fives", 5);
     int score = fives.CalculateScoreForRoll(dieSet.getCount());
     Assert.IsTrue(score == 5);
 }
Exemplo n.º 18
0
 public void TestTwosSomeTwos()
 {
     DieSet dieSet = new DieSet(1, 1, 2, 2, 3);
     ScoringCategory twos = new UpperCategory("Twos", 2);
     int score = twos.CalculateScoreForRoll(dieSet.getCount());
     Assert.IsTrue(score == 4);
 }
Exemplo n.º 19
0
 public void TestTwosNoTwo()
 {
     DieSet dieSet = new DieSet(1, 3, 4, 5, 6);
     ScoringCategory twos = new UpperCategory("Twos", 2);
     int score = twos.CalculateScoreForRoll(dieSet.getCount());
     Assert.IsTrue(score == 0);
 }
Exemplo n.º 20
0
 public void TestFoursSomeFours()
 {
     DieSet dieSet = new DieSet(4, 1, 2, 3, 4);
     ScoringCategory fours = new UpperCategory("Fours", 4);
     int score = fours.CalculateScoreForRoll(dieSet.getCount());
     Assert.IsTrue(score == 8);
 }
Exemplo n.º 21
0
 public void TestSixesSomeSixes()
 {
     DieSet dieSet = new DieSet(1, 2, 5, 6, 6);
     ScoringCategory sixes = new UpperCategory("Sixes", 6);
     int score = sixes.CalculateScoreForRoll(dieSet.getCount());
     Assert.IsTrue(score == 12);
 }
 public void TestFourOfAKind()
 {
     DieSet die = new DieSet(3, 3, 3, 3, 1);
     ScoringCategory fourKind = new FourOfAKindCategory();
     int score = fourKind.CalculateScoreForRoll(die.getCount());
     Assert.IsTrue(score == 13);
 }
 public void TestLargeStraightAltJoker()
 {
     DieSet dieSet = new DieSet(5, 5, 5, 5, 5);
     ScoringCategory largeStraightAlt = new LargeStraightAltCategory();
     int score = largeStraightAlt.Score(dieSet.getCount(), true);
     Assert.AreEqual(20, score);
 }
 public void TestFourOfAKindAltNoScore()
 {
     DieSet die = new DieSet(1, 2, 3, 4, 5);
     ScoringCategory fourKindAlt = new FourOfAKindAltCategory();
     int score = fourKindAlt.CalculateScoreForRoll(die.getCount());
     Assert.IsTrue(score == 0);
 }
 public void TestLittleStraightJoker()
 {
     DieSet dieSet = new DieSet(1, 1, 1, 1, 1);
     ScoringCategory littleStraight = new LittleStraightCategory();
     int score = littleStraight.Score(dieSet.getCount(), true);
     Assert.AreEqual(30, score);
 }
Exemplo n.º 26
0
 public void TestOnePairNoScore()
 {
     DieSet die = new DieSet(1, 2, 3, 4, 5);
     ScoringCategory onePair = new OnePairCategory();
     int score = onePair.CalculateScoreForRoll(die.getCount());
     Assert.IsTrue(score == 0);
 }
 public void TestThreeofAKindAltMore()
 {
     DieSet die = new DieSet(6, 6, 6, 6, 6);
     ScoringCategory threeKindAlt = new ThreeOfAKindAltCategory();
     int score = threeKindAlt.CalculateScoreForRoll(die.getCount());
     Assert.AreEqual(18, score);
 }
Exemplo n.º 28
0
 public void TestOnePairUseHighestPair()
 {
     DieSet die = new DieSet(3, 3, 4, 4, 5);
     ScoringCategory onePair = new OnePairCategory();
     int score = onePair.CalculateScoreForRoll(die.getCount());
     Assert.AreEqual(8, score);
 }
 public void TestThreeOfAKindAlt()
 {
     DieSet die = new DieSet(6, 6, 6, 1, 2);
     ScoringCategory threeKindAlt = new ThreeOfAKindAltCategory();
     int score = threeKindAlt.CalculateScoreForRoll(die.getCount());
     Assert.IsTrue(score == 18);
 }
Exemplo n.º 30
0
 public void TestOnePairMoreThan2()
 {
     DieSet die = new DieSet(6, 6, 5, 6, 6);
     ScoringCategory onePair = new OnePairCategory();
     int score = onePair.CalculateScoreForRoll(die.getCount());
     Assert.AreEqual(12, score);
 }