We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 6a81378 + 8912847 commit 5c0c1d5Copy full SHA for 5c0c1d5
tests/06_Query/QOM/Sql2ToQomConverterTest.php
@@ -75,4 +75,18 @@ public function testQueries()
75
}
76
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
+ }
92
0 commit comments