Example #1
0
        public void ShouldThrowBusinessExceptionWhileDeletingMandatoryListWhenWrongStatus()
        {
            MandatoryList mandatoryList = new MandatoryListDefault().GetMandatoryListWithStatusWaitingApprove();

            var e = Assert.Throws <BusinessRuleException>(() => mandatoryList.Delete());

            Assert.Equal(Resources.SharedResources.ErrorMessages.NotAddedAuthorized, e.Message);
        }
Example #2
0
        public void ShouldDeleteMandatoryList()
        {
            MandatoryList mandatoryList = new MandatoryListDefault().GetMandatoryListWithProdcuts();

            mandatoryList.Delete();

            Assert.False(mandatoryList.IsActive);
        }