void GivenA51CardDeck_Shuffle_ReturnsAShuffled52CardDeck() { _packOfCards.TakeCardFromTopOfPack(); Assert.Equal(51, _packOfCards.Count()); _packOfCards.Shuffle(); Assert.Equal(52, _packOfCards.Count()); }
public void TheCardShouldNoLongerBeInThePackAfterACardIsRemoved() { IPackOfCardsCreator packOfCardsCreator = new PackOfCardsCreator(); IPackOfCards packOfCards = packOfCardsCreator.Create(); ICard cardRemoved = packOfCards.TakeCardFromTopOfPack(); CollectionAssert.DoesNotContain(packOfCards, cardRemoved); }
public void TheCountOfThePackShouldDecreaseByOneAfterACardIsTakenFromTheTop() { IPackOfCardsCreator packOfCardsCreator = new PackOfCardsCreator(); IPackOfCards packOfCards = packOfCardsCreator.Create(); int countBeforeTheCardIsRemoved = packOfCards.Count; int expectedCountAfterCut = countBeforeTheCardIsRemoved - 1; ICard card = packOfCards.TakeCardFromTopOfPack(); int countResult = packOfCards.Count; Assert.AreEqual(expectedCountAfterCut, countResult); }