Commit graph

13 commits

Author SHA1 Message Date
Nikita Popov
992b5f2e08 Make it easier to run curl tests standalone
Fall back to PHP_BINARY if TEST_PHP_EXECUTABLE not given.
2021-08-31 16:53:43 +02:00
Nikita Popov
e989492f1a Drop handling for PHP_CURL_HTTP_REMOVE_SERVER
Historically it was necessary to use a separate server to test
curl against. For many years now we use the builtin server instead.
I don't believe there's much point in retaining this functionality.
2021-06-11 12:55:03 +02:00
Sara Golemon
bfa8e42a55
Use ephemeral ports during curl tests with dev server 2020-09-17 14:44:12 +00:00
Nikita Popov
17f7fb7605 Switch to using shell-less proc_open() in various server tests 2019-07-11 15:48:10 +02:00
Peter Kokot
d6c05c6cd1 Rename two *.php files in tests folders
Current run-tests.php script produces the `*.php` files from the
*.phpt. So all *.php files in tests folders are ignored by Git.

To avoid confusion and to for bettere consistency this patch renames
two remaining tests/*/*.php files to *.inc and *.phar as current
practice in *.phpt files.

- The `ext/curl/tests/resonder/get.php` to .inc extension
- The `ext/phar/tests/files/pear2coverage.phar.php` to .phar extension
2018-10-20 10:11:29 +02:00
Peter Kokot
1ad08256f3 Sync leading and final newlines in source code files
This patch adds missing newlines, trims multiple redundant final
newlines into a single one, and trims redundant leading newlines.

According to POSIX, a line is a sequence of zero or more non-' <newline>'
characters plus a terminating '<newline>' character. [1] Files should
normally have at least one final newline character.

C89 [2] and later standards [3] mention a final newline:
"A source file that is not empty shall end in a new-line character,
which shall not be immediately preceded by a backslash character."

Although it is not mandatory for all files to have a final newline
fixed, a more consistent and homogeneous approach brings less of commit
differences issues and a better development experience in certain text
editors and IDEs.

[1] http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap03.html#tag_03_206
[2] https://port70.net/~nsz/c/c89/c89-draft.html#2.1.1.2
[3] https://port70.net/~nsz/c/c99/n1256.html#5.1.1.2
2018-10-14 12:56:38 +02:00
Anatol Belski
ef9922faa9 Merge branch 'PHP-7.2'
* PHP-7.2:
  Fix curl tests wrt. AppVeyor and curl updates
2018-05-18 17:44:48 +02:00
Anatol Belski
b2429259af Fix curl tests wrt. AppVeyor and curl updates 2018-05-18 17:39:12 +02:00
Gabriel Caruso
21e3b0c70c Remove trailing whitespace in inc files 2018-02-10 19:20:23 +01:00
Mitch Hagstrand
fd92b91188
Increase wait time for tests involving sockets to improve Travis relability
1. Increased sleep time from 25ms to 50ms
2. Added sleep to shutdown handlers
2017-01-13 06:45:04 +00:00
Mitch Hagstrand
2d51267c07 Makes the sapi web server and curl tests more reliable
1. Increased the time for the sapi/cli/tests/php_cli_server.inc to accept connections.
2. sapi/cli/tests/php_cli_server.inc has errors messages and a `stop` function.
3. bug67429.phpt uses the `stop` function to shutdown the webserver before starting a new one.
4. Removed ext/curl/tests/bug48203_multi-win32.phpt test now that ext/curl/tests/bug48203_multi.phpt
   runs on Windows also.
2016-12-27 21:52:05 +01:00
Mitch Hagstrand
92678d1a83 Fixes the curl tests to be more reliable in Travis CI
1. Increases the amount of time for the PHP built-in server to accept a connection
2. Outputs an error if the PHP built-in server fails
3. In bug48203_multi.phpt the test no longer starts and stops multiple PHP built-in servers
2016-12-27 21:52:05 +01:00
Stanislav Malyshev
41b655d9cd improve CURL tests to allow testing without separate server 2014-05-11 23:04:09 -07:00