Not equal
Inheritance: BinaryLogicalOp
Exemplo n.º 1
0
        public void Evaluate_NotEqual_Int_False_Test()
        {
            Expression left = CreateIntLiteral(1);
            Expression right = CreateIntLiteral(1);

            Expression notEqual = new NotEqual(left, right, pos);

            Values.Bool value = ((Values.Bool)notEqual.Accept(evaluator));

            Assert.IsFalse(value.GetValue());
        }
Exemplo n.º 2
0
        public void Evaluate_NotEqual_String_True_Test()
        {
            Expression left = CreateStringLiteral("equal");
            Expression right = CreateStringLiteral("notEqual");

            Expression notEqual = new NotEqual(left, right, pos);

            Values.Bool value = ((Values.Bool)notEqual.Accept(evaluator));

            Assert.IsTrue(value.GetValue());
        }
Exemplo n.º 3
0
        public void Evaluate_NotEqual_Bool_True_Test()
        {
            Expression left = CreateBoolLiteral(true);
            Expression right = CreateBoolLiteral(false);

            Expression notEqual = new NotEqual(left, right, pos);

            Values.Bool value = ((Values.Bool)notEqual.Accept(evaluator));

            Assert.IsTrue(value.GetValue());
        }