Skip to content

Commit df63910

Browse files
committed
Fix build with latest PHPStan
1 parent d930145 commit df63910

File tree

6 files changed

+33
-41
lines changed

6 files changed

+33
-41
lines changed

tests/default/config/.phpunit-phpstan-dba-pdo-mysql.cache

Lines changed: 0 additions & 8 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

tests/default/data/pdo-mysql.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ public function aggregateFunctions(PDO $pdo)
2121
$query = 'SELECT MAX(adaid), MIN(adaid), COUNT(adaid), AVG(adaid) FROM ada WHERE adaid = 1';
2222
$stmt = $pdo->query($query, PDO::FETCH_ASSOC);
2323
foreach ($stmt as $row) {
24-
assertType('array{MAX(adaid): int<-32768, 32767>|null, MIN(adaid): int<-32768, 32767>|null, COUNT(adaid): int, AVG(adaid): numeric-string|null}', $row);
24+
assertType("array{'MAX(adaid)': int<-32768, 32767>|null, 'MIN(adaid)': int<-32768, 32767>|null, 'COUNT(adaid)': int, 'AVG(adaid)': numeric-string|null}", $row);
2525
}
2626
}
2727

tests/sqlAst/config/.phpunit-phpstan-dba-mysqli.cache

Lines changed: 15 additions & 15 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

tests/sqlAst/config/.phpunit-phpstan-dba-pdo-mysql.cache

Lines changed: 15 additions & 15 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

tests/sqlAst/data/sql-ast-narrowing.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,7 @@ public function count(PDO $pdo): void
141141

142142
$stmt = $pdo->query('SELECT count(email) as myemail, count(email) from ada');
143143
foreach ($stmt as $row) {
144-
assertType('array{myemail: int<0, max>, 0: int<0, max>, count(email): int<0, max>, 1: int<0, max>}', $row);
144+
assertType("array{myemail: int<0, max>, 0: int<0, max>, 'count(email)': int<0, max>, 1: int<0, max>}", $row);
145145
}
146146
}
147147

tests/stringify/data/ast-narrowed-stringify.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ public function count(PDO $pdo): void
1616

1717
$stmt = $pdo->query('SELECT count(email) as myemail, count(email) from ada');
1818
foreach ($stmt as $row) {
19-
assertType("array{myemail: numeric-string, 0: numeric-string, count(email): numeric-string, 1: numeric-string}", $row);
19+
assertType("array{myemail: numeric-string, 0: numeric-string, 'count(email)': numeric-string, 1: numeric-string}", $row);
2020
}
2121
}
2222
}

0 commit comments

Comments
 (0)