[php-src] PR #15470: Avoid multiple connects in SKIPIF sections
| From: | cmb69 | Date: | Sat, 17 Aug 2024 16:48:25 +0000 |
| Subject: | [php-src] PR #15470: Avoid multiple connects in SKIPIF sections | ||
| Groups: | php.git-pulls | ||
| Request: | Send a blank email to git-pulls+get-28032@lists.php.net to get a copy of this message | ||
Pull Request: https://github.com/php/php-src/pull/15470
Author: cmb69
Besides checking for the ability to connect to the MySQL server, some tests require additional
checks (e.g. to be able to check for the server's version) as skip condition. There is no
need, though, to connect twice; instead we introduce
mysqli_connect_or_skip() in
test_helpers.inc, which die()s with an appropriate error message, if the connection
can't be established, or returns the connection link otherwise.