예제 #1
0
        public void First_High_Card_Wins()
        {
            var pokerGame = new PokerGame(PokerHandTestHelper.CreateHighCardNineHand("John"),
                                          PokerHandTestHelper.CreateHighCardAceHand("Bob"));
            var result = pokerGame.PlayHand();

            Assert.AreEqual(HandRankResult.High_Card, result.RankResult);
            Assert.AreEqual("Bob", result.WinningPlayer);
        }
예제 #2
0
        public void OnePair_Beats_HighCard()
        {
            var pokerGame = new PokerGame(PokerHandTestHelper.CreateHighCardNineHand("John"),
                                          PokerHandTestHelper.CreateOnePairHand("Bob"));
            var result = pokerGame.PlayHand();

            Assert.AreEqual(HandRankResult.One_Pair, result.RankResult);
            Assert.AreEqual("Bob", result.WinningPlayer);
        }