Skip to content

Commit

Permalink
fix tests for detailed $_SERVER
Browse files Browse the repository at this point in the history
  • Loading branch information
kkmuffme committed Sep 11, 2022
1 parent 7a45e9e commit d81033b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions tests/AssertAnnotationTest.php
Expand Up @@ -375,7 +375,7 @@ function isInvalidString(?string $myVar) : bool {
echo "Ma chaine " . $myString;
}',
],
'assertServerVar' => [
'assertSessionVar' => [
'<?php
namespace Bar;
Expand All @@ -388,8 +388,8 @@ function my_is_string($a) : bool
return is_string($a);
}
if (my_is_string($_SERVER["abc"])) {
$i = substr($_SERVER["abc"], 1, 2);
if (my_is_string($_SESSION["abc"])) {
$i = substr($_SESSION["abc"], 1, 2);
}',
],
'dontBleedBadAssertVarIntoContext' => [
Expand Down
6 changes: 3 additions & 3 deletions tests/TypeReconciliation/ConditionalTest.php
Expand Up @@ -768,10 +768,10 @@ function d(?iterable $foo): void {
}
}',
],
'isStringServerVar' => [
'isStringSessionVar' => [
'<?php
if (is_string($_SERVER["abc"])) {
echo substr($_SERVER["abc"], 1, 2);
if (is_string($_SESSION["abc"])) {
echo substr($_SESSION["abc"], 1, 2);
}',
],
'notObject' => [
Expand Down

0 comments on commit d81033b

Please sign in to comment.