Example #1
0
        public void CostTypeRule01CatchesCostTypesNotInValidList()
        {
            var model = new SupplementaryDataModel
            {
                CostType = "I am not valid"
            };
            var rule = new CostTypeRule01();

            Assert.False(rule.Execute(model));
        }
Example #2
0
        public void CostTypeRule01PassesValidCostTypes()
        {
            var model = new SupplementaryDataModel
            {
                CostType = "Grant"
            };
            var rule = new CostTypeRule01(_messageServiceMock.Object);

            Assert.True(rule.IsValid(model));
        }
Example #3
0
        public void CostTypeRule01PassesValidCostTypes()
        {
            var model = new SupplementaryDataModel
            {
                CostType = "Grant"
            };
            var rule = new CostTypeRule01();

            Assert.True(rule.Execute(model));
        }
Example #4
0
        public void CostTypeRule01CatchesCostTypesNotInValidList()
        {
            var model = new SupplementaryDataModel
            {
                CostType = "I am not valid"
            };
            var rule = new CostTypeRule01(_messageServiceMock.Object);

            Assert.False(rule.IsValid(model));
        }