public void WhenCardIsConstructedWithShortNotation(string shortNotation, Value expectedValue, Suit expectedSuit) { var card = new Card(shortNotation); Assert.That(card.Value, Is.EqualTo(expectedValue)); Assert.That(card.Suit, Is.EqualTo(expectedSuit)); }
public void WhenCardIsConstructedWithInvalidValue() { Assert.That(() => { var card = new Card("WD"); }, Throws.ArgumentException.With.Message.EqualTo("Invalid card value")); }
public void WhenCardIsConstructedWithInvalidShortNotation() { Assert.That(() => { var card = new Card(""); }, Throws.ArgumentException.With.Message.EqualTo("Card notation must be two characters")); }