public void WhenMakingATrade_JackCannotGiveHisCowAway()
        {
            // Arrange
            Jack   jack;
            Action action;

            // Act
            jack   = new Jack();
            action = () => jack.TradeCowForBeans(0);


            // Assert
            Assert.Throws <InvalidOperationException>(action);
        }
        public void WhenMakingATrade_JackShouldNotBeGreedy(int beans)
        {
            // Arrange
            Jack   jack;
            Action action;

            // Act
            jack   = new Jack();
            action = () => jack.TradeCowForBeans(beans);


            // Assert
            Assert.Throws <InvalidOperationException>(action);
        }
        public void WhenMakingATrade_JackShouldOnlyBeAbleToSellHisCowForBetweenOneAndFiveBeans(int beans)
        {
            // Arrange
            Jack jack;

            // Act
            jack = new Jack();
            jack.TradeCowForBeans(beans);


            // Assert
            Assert.Equal(0, jack.Cows);
            Assert.Equal(beans, jack.MagicBeans);
        }