This commit is contained in:
2015-04-29 09:24:59 +02:00
parent d089eedb19
commit 43e313beb4
3 changed files with 4 additions and 239 deletions

View File

@@ -39,32 +39,4 @@ public class PokerGameTest {
assertEquals("White", winningPlayer.getPlayerName());
}
@Test
public void straight_gives_12() throws Exception {
String hand = "K2S3H4R5R6";
int result = myGame.getScore(hand);
assertEquals(12, result);
}
@Test
public void straight_flush_gives_14() throws Exception {
String hand = "K2K3K4K5K6";
int result = myGame.getScore(hand);
assertEquals(14, result);
}
@Test
@Ignore
public void royal_straight_flush_gives_16() throws Exception {
String hand = "R10RKRDRKRE";
int result = myGame.getScore(hand);
assertEquals(16, result);
}
}

View File

@@ -1,8 +1,7 @@
package session3;
import static org.junit.Assert.*;
import org.junit.Test;
import src.session3.Player;
import src.session3.TwoPairRule;
public class TwoPairRuleTest {
@@ -27,7 +26,7 @@ public class TwoPairRuleTest {
assertEquals("Green", winningPlayer.getPlayerName());
}
@Test
public void first_pair_tie_second_pair_highest_wins() throws Exception {
Player green = new Player("Green", "9S 9C 6D 6H AH");
@@ -35,6 +34,6 @@ public class TwoPairRuleTest {
Player winningPlayer = TwoPairRule.compare(white, green);
assertEquals("Green", winningPlayer.getPlayerName());
assertEquals("Green", winningPlayer.getPlayerName());
}
}