File tree Expand file tree Collapse file tree 1 file changed +14
-0
lines changed Expand file tree Collapse file tree 1 file changed +14
-0
lines changed Original file line number Diff line number Diff line change @@ -75,4 +75,18 @@ public function testQueries()
75
75
}
76
76
}
77
77
}
78
+
79
+ public function testPropertyComparisonWithWhitespace ()
80
+ {
81
+ $ sql2 = 'SELECT * FROM [nt:file] WHERE prop1 = "Foo bar" ' ;
82
+
83
+ $ qom = $ this ->parser ->parse ($ sql2 );
84
+
85
+ $ this ->assertInstanceOf ('PHPCR\Query\QOM\ComparisonInterface ' , $ qom ->getConstraint ());
86
+ $ this ->assertInstanceOf ('PHPCR\Query\QOM\PropertyValueInterface ' , $ qom ->getConstraint ()->getOperand1 ());
87
+ $ this ->assertInstanceOf ('PHPCR\Query\QOM\LiteralInterface ' , $ qom ->getConstraint ()->getOperand2 ());
88
+
89
+ $ this ->assertEquals ('prop1 ' , $ qom ->getConstraint ()->getOperand1 ()->getPropertyName ());
90
+ $ this ->assertEquals ('Foo bar ' , $ qom ->getConstraint ()->getOperand2 ()->getLiteralValue ());
91
+ }
78
92
}
You can’t perform that action at this time.
0 commit comments