@@ -164,6 +164,42 @@ class SqlExecutionTest extends InlineExpectationsTest {
164164 }
165165}
166166
167+ class XPathConstructionTest extends InlineExpectationsTest {
168+ XPathConstructionTest ( ) { this = "XPathConstructionTest" }
169+
170+ override string getARelevantTag ( ) { result = "constructedXPath" }
171+
172+ override predicate hasActualResult ( Location location , string element , string tag , string value ) {
173+ exists ( location .getFile ( ) .getRelativePath ( ) ) and
174+ exists ( XPathConstruction e , DataFlow:: Node xpath |
175+ exists ( location .getFile ( ) .getRelativePath ( ) ) and
176+ xpath = e .getXPath ( ) and
177+ location = e .getLocation ( ) and
178+ element = xpath .toString ( ) and
179+ value = prettyNodeForInlineTest ( xpath ) and
180+ tag = "constructedXPath"
181+ )
182+ }
183+ }
184+
185+ class XPathExecutionTest extends InlineExpectationsTest {
186+ XPathExecutionTest ( ) { this = "XPathExecutionTest" }
187+
188+ override string getARelevantTag ( ) { result = "getXPath" }
189+
190+ override predicate hasActualResult ( Location location , string element , string tag , string value ) {
191+ exists ( location .getFile ( ) .getRelativePath ( ) ) and
192+ exists ( XPathExecution e , DataFlow:: Node xpath |
193+ exists ( location .getFile ( ) .getRelativePath ( ) ) and
194+ xpath = e .getXPath ( ) and
195+ location = e .getLocation ( ) and
196+ element = xpath .toString ( ) and
197+ value = prettyNodeForInlineTest ( xpath ) and
198+ tag = "getXPath"
199+ )
200+ }
201+ }
202+
167203class EscapingTest extends InlineExpectationsTest {
168204 EscapingTest ( ) { this = "EscapingTest" }
169205
0 commit comments