Skip to content

Commit 5a3c4a2

Browse files
committed
Fix test when using libmysqlclient
TL;DR When suing libmysqlclient, ints are fetched as strings, so the strict comparison was failing
1 parent 11914de commit 5a3c4a2

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

ext/pdo_mysql/tests/pdo_mysql_parser.phpt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ $queries = [
2929
foreach ($queries as $k => $query) {
3030
$stmt = $db->prepare($query);
3131
$stmt->execute();
32-
var_dump($query, $stmt->fetch(PDO::FETCH_NUM) === [0 => 1]);
32+
var_dump($query, $stmt->fetch(PDO::FETCH_NUM) == [0 => 1]);
3333
}
3434

3535
// One parameter
@@ -43,7 +43,7 @@ $queries = [
4343
foreach ($queries as $k => $query) {
4444
$stmt = $db->prepare($query);
4545
$stmt->execute([1]);
46-
var_dump($query, $stmt->fetch(PDO::FETCH_NUM) === [0 => 1]);
46+
var_dump($query, $stmt->fetch(PDO::FETCH_NUM) == [0 => 1]);
4747
}
4848

4949
$db->exec("DROP TABLE pdo_mysql_parser");

0 commit comments

Comments
 (0)