示例#1
0
 public void RulesCanBeCombinedUsingTheImpliesOperator()
 {
     Assert.That(aRuleThatIsTrue.Implies(aRuleThatIsTrue).IsTrueFor(new AnyClass()));
     Assert.That(aRuleThatIsTrue.Implies(aRuleThatIsFalse).IsFalseFor(new AnyClass()));
     Assert.That(aRuleThatIsFalse.Implies(aRuleThatIsTrue).IsTrueFor(new AnyClass()));
     Assert.That(aRuleThatIsFalse.Implies(aRuleThatIsFalse).IsTrueFor(new AnyClass()));
 }
示例#2
0
        public void AnImpliesRuleCanBeDescribed()
        {
            var rule = aRuleThatIsTrue.Implies(aRuleThatIsFalse);

            var description = describer.Describe(rule);

            Assert.That(description, Is.EqualTo("(Always True IMPLIES Always False)"));
        }
        public void AnImpliesRuleCanBeEvaluatedAndDescribed()
        {
            var rule = aRuleThatIsTrue.Implies(aRuleThatIsFalse);

            var description = describer.Describe(rule);

            Assert.That(description, Is.EqualTo("Always True[T] IMPLIES[F] Always False[F]"));
        }