Example #1
0
        public void can_access_deck_cards()
        {
            // Arrange
            IDeck deck = new Deck();

            // Act
            var cards = deck.GetCards();

            // Assert
            cards.Count().Should().Equal(52);
        }
Example #2
0
        public void base_deck_contains_all_52_cards()
        {
            // Arrange
            IDeck deck = new Deck();

            // Act
            // Assert
            for (var suit = 0; suit < 4; suit++)
            {
                for (var rank = 1; rank < 14; rank++)
                {
                    var r = (Rank) rank;
                    var s = (Suit) suit;

                    deck.ContainsCard(r, s).Should().Be.True();
                }
            }
        }