summaryrefslogtreecommitdiff
path: root/ext/mysqli/tests/mysqli_ping.phpt
diff options
context:
space:
mode:
Diffstat (limited to 'ext/mysqli/tests/mysqli_ping.phpt')
-rw-r--r--ext/mysqli/tests/mysqli_ping.phpt40
1 files changed, 20 insertions, 20 deletions
diff --git a/ext/mysqli/tests/mysqli_ping.phpt b/ext/mysqli/tests/mysqli_ping.phpt
index 6ddb29efef..9fa3ac8cae 100644
--- a/ext/mysqli/tests/mysqli_ping.phpt
+++ b/ext/mysqli/tests/mysqli_ping.phpt
@@ -8,36 +8,36 @@ require_once('skipifconnectfailure.inc');
?>
--FILE--
<?php
- require_once("connect.inc");
+ require_once("connect.inc");
- $tmp = NULL;
- $link = NULL;
+ $tmp = NULL;
+ $link = NULL;
- if (!is_null($tmp = @mysqli_ping()))
- printf("[001] Expecting NULL, got %s/%s\n", gettype($tmp), $tmp);
+ if (!is_null($tmp = @mysqli_ping()))
+ printf("[001] Expecting NULL, got %s/%s\n", gettype($tmp), $tmp);
- require('table.inc');
+ require('table.inc');
- if (!is_null($tmp = @mysqli_ping($link, $link)))
- printf("[002] Expecting NULL, got %s/%s\n", gettype($tmp), $tmp);
+ if (!is_null($tmp = @mysqli_ping($link, $link)))
+ printf("[002] Expecting NULL, got %s/%s\n", gettype($tmp), $tmp);
- var_dump(mysqli_ping($link));
+ var_dump(mysqli_ping($link));
- // provoke an error to check if mysqli_ping resets it
- $res = mysqli_query($link, 'SELECT * FROM unknown_table');
- if (!($errno = mysqli_errno($link)))
- printf("[003] Statement should have caused an error\n");
+ // provoke an error to check if mysqli_ping resets it
+ $res = mysqli_query($link, 'SELECT * FROM unknown_table');
+ if (!($errno = mysqli_errno($link)))
+ printf("[003] Statement should have caused an error\n");
- var_dump(mysqli_ping($link));
- if ($errno === mysqli_errno($link))
- printf("[004] Error codes should have been reset\n");
+ var_dump(mysqli_ping($link));
+ if ($errno === mysqli_errno($link))
+ printf("[004] Error codes should have been reset\n");
- mysqli_close($link);
+ mysqli_close($link);
- if (false !== ($tmp = mysqli_ping($link)))
- printf("[005] Expecting false, got %s/%s\n", gettype($tmp), $tmp);
+ if (false !== ($tmp = mysqli_ping($link)))
+ printf("[005] Expecting false, got %s/%s\n", gettype($tmp), $tmp);
- print "done!";
+ print "done!";
?>
--EXPECTF--
bool(true)