1
0
mirror of https://github.com/danog/psalm.git synced 2024-11-26 20:34:47 +01:00

Fix tests

This commit is contained in:
cgocast 2023-08-31 05:20:39 +02:00
parent c16216bc42
commit 5545873f44
2 changed files with 5 additions and 5 deletions

View File

@ -1,4 +1,4 @@
# TaintedSql
# TaintedXpath
Emitted when user-controlled input can be passed into to a xpath query.

View File

@ -749,7 +749,7 @@ class TaintTest extends TestCase
$d = mysqli_real_escape_string($_GET["d"]);
$mysqli->query("$a$b$c$d");',
],
],
'querySimpleXMLElement' => [
'code' => '<?php
/**
@ -2521,7 +2521,7 @@ class TaintTest extends TestCase
function queryExpression(SimpleXMLElement $xml) : array|false|null {
$expression = $_GET["expression"];
return $xml->xpath($expression);
}',
}',
'error_message' => 'TaintedXpath',
],
'queryDOMXPath' => [
@ -2529,7 +2529,7 @@ class TaintTest extends TestCase
function queryExpression(DOMXPath $xpath) : mixed {
$expression = $_GET["expression"];
return $xpath->query($expression);
}',
}',
'error_message' => 'TaintedXpath',
],
'evaluateDOMXPath' => [
@ -2537,7 +2537,7 @@ class TaintTest extends TestCase
function evaluateExpression(DOMXPath $xpath) : mixed {
$expression = $_GET["expression"];
return $xpath->evaluate($expression);
}',
}',
'error_message' => 'TaintedXpath',
],
];