Exemplo n.º 1
0
        public void AddUnitsThrowsExceptionNegativeInput()
        {
            //arrange
            var sut = new GoodItem();

            //act
            //assert
            System.Exception ex = Assert.Throws <WeLoveTaxesDomainException>(() => sut.AddUnits(-5));
        }
Exemplo n.º 2
0
        public void AddUnitsWorksFine()
        {
            //arrange
            var sut = new GoodItem(24, 1, true, GoodItemTypeEnum.Other, null, new GoodItemDetails());

            //act
            sut.AddUnits(7);
            //assert
            Assert.Equal(8, sut.GetUnits());
        }