Skip to content

Commit 81fba27

Browse files
committed
ext/pdo_pgsql: Remove bool type coercions in tests
1 parent c26003d commit 81fba27

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

ext/pdo_pgsql/tests/getnotify.phpt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -69,17 +69,17 @@ var_dump($db->pgsqlGetNotify());
6969

7070

7171
// Test second parameter, should wait 2 seconds because no notify is queued
72-
$t = microtime(1);
72+
$t = microtime(true);
7373
$notify = $db->pgsqlGetNotify(PDO::FETCH_ASSOC, 1000);
74-
$diff = microtime(1) - $t;
74+
$diff = microtime(true) - $t;
7575
var_dump($diff >= 1 || 1 - abs($diff) < .05);
7676
var_dump($notify);
7777

7878
// Test second parameter, should return immediately because a notify is queued
7979
$db->exec("NOTIFY channel_getnotify");
80-
$t = microtime(1);
80+
$t = microtime(true);
8181
$notify = $db->pgsqlGetNotify(PDO::FETCH_ASSOC, 5000);
82-
$diff = microtime(1) - $t;
82+
$diff = microtime(true) - $t;
8383
var_dump($diff < 1 || abs(1 - abs($diff)) < .05);
8484
var_dump(count($notify));
8585

0 commit comments

Comments
 (0)