Ejemplo n.º 1
0
        public void EvaluateReturnsTrueIfSubExpressionReturnsTypedLiteral()
        {
            IsLiteral expression = new IsLiteral(new GraphMemberExpression(new TypedLiteral("scooby", "http://example.com/dog")));
            Bindings  bindings   = new Bindings();

            Assert.AreEqual(true, expression.Evaluate(bindings));
        }
Ejemplo n.º 2
0
        public void EvaluateReturnsFalseIfSubExpressionDoesntReturnPlainLiteralOrTypedLiteral()
        {
            IsLiteral expression = new IsLiteral(new GraphMemberExpression(new BlankNode()));
            Bindings  bindings   = new Bindings();

            Assert.AreEqual(false, expression.Evaluate(bindings));
        }
Ejemplo n.º 3
0
        public void EvaluateReturnsTrueIfSubExpressionReturnsPlainLiteral()
        {
            IsLiteral expression = new IsLiteral(new GraphMemberExpression(new PlainLiteral("scooby")));
            Bindings  bindings   = new Bindings();

            Assert.AreEqual(true, expression.Evaluate(bindings));
        }