Skip to content

Commit bfe63f5

Browse files
Yurunsoftdevnexen
authored andcommitted
Fix dblib ghtest8626 test.
Follow-up of phpGH-8628. Closes phpGH-9694.
1 parent 0a47fdf commit bfe63f5

File tree

1 file changed

+2
-8
lines changed

1 file changed

+2
-8
lines changed

ext/pdo/tests/gh8626.phpt

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -24,20 +24,14 @@ $stmt = $db->prepare('INSERT INTO test VALUES(?)');
2424
// fail
2525
var_dump($stmt->execute([null]), $stmt->errorCode());
2626
$errorInfo = $stmt->errorInfo();
27-
if (isset($errorInfo[3])) {
28-
unset($errorInfo[3]); // odbc
29-
}
30-
var_dump($errorInfo);
27+
var_dump(array_slice($errorInfo, 0, 3)); // odbc, dblib
3128

3229
$stmt->closeCursor(); // sqlite
3330

3431
// success
3532
var_dump($stmt->execute([1]), $stmt->errorCode());
3633
$errorInfo = $stmt->errorInfo();
37-
if (isset($errorInfo[3])) {
38-
unset($errorInfo[3]); // odbc
39-
}
40-
var_dump($errorInfo);
34+
var_dump(array_slice($errorInfo, 0, 3)); // odbc, dblib
4135
?>
4236
===DONE===
4337
--EXPECTF--

0 commit comments

Comments
 (0)