diff options
author | Nikita Popov <nikita.ppv@gmail.com> | 2020-02-03 22:52:20 +0100 |
---|---|---|
committer | Nikita Popov <nikita.ppv@gmail.com> | 2020-02-03 22:52:20 +0100 |
commit | f8d795820e780a6322e054c26c581570613c14f0 (patch) | |
tree | 99d3ae01ce564752807341c5743863b4c92513f8 /ext/mysqli/tests/mysqli_kill.phpt | |
parent | d2cb200e10ada6fa44c54a29292bb4665728fff0 (diff) | |
download | php-git-f8d795820e780a6322e054c26c581570613c14f0.tar.gz |
Reindent phpt files
Diffstat (limited to 'ext/mysqli/tests/mysqli_kill.phpt')
-rw-r--r-- | ext/mysqli/tests/mysqli_kill.phpt | 84 |
1 files changed, 42 insertions, 42 deletions
diff --git a/ext/mysqli/tests/mysqli_kill.phpt b/ext/mysqli/tests/mysqli_kill.phpt index f4af490a5b..943e213a81 100644 --- a/ext/mysqli/tests/mysqli_kill.phpt +++ b/ext/mysqli/tests/mysqli_kill.phpt @@ -8,61 +8,61 @@ require_once('skipifconnectfailure.inc'); ?> --FILE-- <?php - require_once("connect.inc"); + require_once("connect.inc"); - require('table.inc'); + require('table.inc'); - // Zend will cast the NULL to 0 - if (!is_bool($tmp = mysqli_kill($link, null))) - printf("[003] Expecting boolean/any, got %s/%s\n", gettype($tmp), $tmp); + // Zend will cast the NULL to 0 + if (!is_bool($tmp = mysqli_kill($link, null))) + printf("[003] Expecting boolean/any, got %s/%s\n", gettype($tmp), $tmp); - if (!$thread_id = mysqli_thread_id($link)) - printf("[004] Cannot determine thread id, [%d] %s\n", mysqli_errno($link), mysqli_error($link)); + if (!$thread_id = mysqli_thread_id($link)) + printf("[004] Cannot determine thread id, [%d] %s\n", mysqli_errno($link), mysqli_error($link)); - $tmp = mysqli_kill($link, $thread_id); - if (!is_bool($tmp)) - printf("[005] Expecting boolean/any, got %s/%s\n", gettype($tmp), $tmp); + $tmp = mysqli_kill($link, $thread_id); + if (!is_bool($tmp)) + printf("[005] Expecting boolean/any, got %s/%s\n", gettype($tmp), $tmp); - if ($res = mysqli_query($link, "SELECT id FROM test LIMIT 1")) - pintf("[006] Expecting boolean/false, got %s/%s\n", gettype($res), $res); + if ($res = mysqli_query($link, "SELECT id FROM test LIMIT 1")) + pintf("[006] Expecting boolean/false, got %s/%s\n", gettype($res), $res); - var_dump($error = mysqli_error($link)); - if (!is_string($error) || ('' === $error)) - printf("[007] Expecting string/any non empty, got %s/%s\n", gettype($error), $error); - var_dump($res); - var_dump($link); - if ($IS_MYSQLND) { - if ($link->info != 'Records: 6 Duplicates: 0 Warnings: 0') { - printf("[008] mysqlnd used to be more verbose and used to support SELECT\n"); - } - } else { - if ($link->info != NULL) { - printf("[008] Time for wonders - libmysql has started to support SELECT, change test\n"); - } - } + var_dump($error = mysqli_error($link)); + if (!is_string($error) || ('' === $error)) + printf("[007] Expecting string/any non empty, got %s/%s\n", gettype($error), $error); + var_dump($res); + var_dump($link); + if ($IS_MYSQLND) { + if ($link->info != 'Records: 6 Duplicates: 0 Warnings: 0') { + printf("[008] mysqlnd used to be more verbose and used to support SELECT\n"); + } + } else { + if ($link->info != NULL) { + printf("[008] Time for wonders - libmysql has started to support SELECT, change test\n"); + } + } - mysqli_close($link); + mysqli_close($link); - if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) - printf("[010] Cannot connect, [%d] %s\n", mysqli_connect_errno(), mysqli_connect_error()); + if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) + printf("[010] Cannot connect, [%d] %s\n", mysqli_connect_errno(), mysqli_connect_error()); - mysqli_kill($link, -1); - if ((!$res = mysqli_query($link, "SELECT id FROM test LIMIT 1")) || - (!$tmp = mysqli_fetch_assoc($res))) { - printf("[011] Connection should not be gone, [%d] %s\n", mysqli_errno($link), mysqli_error($link)); - } - var_dump($tmp); - mysqli_free_result($res); - mysqli_close($link); + mysqli_kill($link, -1); + if ((!$res = mysqli_query($link, "SELECT id FROM test LIMIT 1")) || + (!$tmp = mysqli_fetch_assoc($res))) { + printf("[011] Connection should not be gone, [%d] %s\n", mysqli_errno($link), mysqli_error($link)); + } + var_dump($tmp); + mysqli_free_result($res); + mysqli_close($link); - if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) - printf("[012] Cannot connect, [%d] %s\n", mysqli_connect_errno(), mysqli_connect_error()); + if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) + printf("[012] Cannot connect, [%d] %s\n", mysqli_connect_errno(), mysqli_connect_error()); - mysqli_change_user($link, "This might work if you accept anonymous users in your setup", "password", $db); mysqli_kill($link, -1); + mysqli_change_user($link, "This might work if you accept anonymous users in your setup", "password", $db); mysqli_kill($link, -1); - mysqli_close($link); + mysqli_close($link); - print "done!"; + print "done!"; ?> --CLEAN-- <?php |