AIMA.Test.Core.Unit.Logic.FOL.UnifierTest.testKnows1 C# (CSharp) Méthode

testKnows1() private méthode

private testKnows1 ( ) : void
Résultat void
        public void testKnows1()
        {
            Sentence query = parser.parse("Knows(John,x)");
            Sentence johnKnowsJane = parser.parse("Knows(John,Jane)");
            Dictionary<Variable, Term> result = unifier.unify(query, johnKnowsJane, theta);
            Assert.AreEqual(theta, result);
            Assert.IsTrue(theta.ContainsKey(new Variable("x"))); // x =
            Assert.AreEqual(new Constant("Jane"), theta[new Variable("x")]); // Jane
        }