diff options
author | Peter Kokot <peterkokot@gmail.com> | 2018-10-15 04:31:31 +0200 |
---|---|---|
committer | Peter Kokot <peterkokot@gmail.com> | 2018-10-15 04:31:31 +0200 |
commit | f1d7e3ca0b70f910fcecef0278de9c15440ca3c0 (patch) | |
tree | 70af7290bf6c0b06f223254537b502013ade302e /ext/curl | |
parent | f98c916845571deeab189fb2ab52a17aef49edb8 (diff) | |
download | php-git-f1d7e3ca0b70f910fcecef0278de9c15440ca3c0.tar.gz |
Sync leading and final newlines in *.phpt sections
This patch adds missing newlines, trims multiple redundant final
newlines into a single one, and trims redundant leading newlines in all
*.phpt sections.
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
Diffstat (limited to 'ext/curl')
-rw-r--r-- | ext/curl/tests/bug48203-win32.phpt | 1 | ||||
-rw-r--r-- | ext/curl/tests/curl_CURLOPT_READDATA.phpt | 1 | ||||
-rw-r--r-- | ext/curl/tests/curl_basic_011.phpt | 1 | ||||
-rw-r--r-- | ext/curl/tests/curl_basic_012.phpt | 2 | ||||
-rw-r--r-- | ext/curl/tests/curl_basic_013.phpt | 2 | ||||
-rw-r--r-- | ext/curl/tests/curl_file_serialize.phpt | 1 | ||||
-rw-r--r-- | ext/curl/tests/curl_setopt_array_basic.phpt | 1 | ||||
-rw-r--r-- | ext/curl/tests/curl_setopt_basic002.phpt | 1 |
8 files changed, 2 insertions, 8 deletions
diff --git a/ext/curl/tests/bug48203-win32.phpt b/ext/curl/tests/bug48203-win32.phpt index d3affdb71d..686a38075b 100644 --- a/ext/curl/tests/bug48203-win32.phpt +++ b/ext/curl/tests/bug48203-win32.phpt @@ -34,4 +34,3 @@ Warning: curl_exec(): CURLOPT_STDERR resource has gone away, resetting to stderr Hello World! Hello World!* Closing connection 0 Ok - diff --git a/ext/curl/tests/curl_CURLOPT_READDATA.phpt b/ext/curl/tests/curl_CURLOPT_READDATA.phpt index 25bd0e9b49..eebf4a0c03 100644 --- a/ext/curl/tests/curl_CURLOPT_READDATA.phpt +++ b/ext/curl/tests/curl_CURLOPT_READDATA.phpt @@ -36,7 +36,6 @@ curl_close($ch); // Clean the temporary file @unlink($tempname); - --EXPECT-- array(2) { ["hello"]=> diff --git a/ext/curl/tests/curl_basic_011.phpt b/ext/curl/tests/curl_basic_011.phpt index 30dd5225a5..294e4e700b 100644 --- a/ext/curl/tests/curl_basic_011.phpt +++ b/ext/curl/tests/curl_basic_011.phpt @@ -36,4 +36,3 @@ TestFest 2009 - AFUP - Xavier Gorse <xgorse@elao.com> *** Testing curl with cookie *** string(3) "bar" ===DONE=== - diff --git a/ext/curl/tests/curl_basic_012.phpt b/ext/curl/tests/curl_basic_012.phpt index c05fc0f030..7788ef5080 100644 --- a/ext/curl/tests/curl_basic_012.phpt +++ b/ext/curl/tests/curl_basic_012.phpt @@ -36,4 +36,4 @@ TestFest 2009 - AFUP - Xavier Gorse <xgorse@elao.com> *** Testing curl with HTTP/1.0 *** string(8) "HTTP/1.0" ===DONE=== -
\ No newline at end of file + diff --git a/ext/curl/tests/curl_basic_013.phpt b/ext/curl/tests/curl_basic_013.phpt index c734cf5cd2..e93db42916 100644 --- a/ext/curl/tests/curl_basic_013.phpt +++ b/ext/curl/tests/curl_basic_013.phpt @@ -36,4 +36,4 @@ TestFest 2009 - AFUP - Xavier Gorse <xgorse@elao.com> *** Testing curl with HTTP/1.1 *** string(8) "HTTP/1.1" ===DONE=== -
\ No newline at end of file + diff --git a/ext/curl/tests/curl_file_serialize.phpt b/ext/curl/tests/curl_file_serialize.phpt index d8eefb355d..e2f2d14fff 100644 --- a/ext/curl/tests/curl_file_serialize.phpt +++ b/ext/curl/tests/curl_file_serialize.phpt @@ -18,4 +18,3 @@ Stack trace: #1 %s #2 {main} thrown in %s on line %d - diff --git a/ext/curl/tests/curl_setopt_array_basic.phpt b/ext/curl/tests/curl_setopt_array_basic.phpt index d858241b78..0ad8fc7eee 100644 --- a/ext/curl/tests/curl_setopt_array_basic.phpt +++ b/ext/curl/tests/curl_setopt_array_basic.phpt @@ -54,4 +54,3 @@ isset($tempname) and is_file($tempname) and @unlink($tempname); == Starting test curl_setopt_array($ch, $options); == string(25) "Hello World! Hello World!" - diff --git a/ext/curl/tests/curl_setopt_basic002.phpt b/ext/curl/tests/curl_setopt_basic002.phpt index 7a11493ed2..72754d989a 100644 --- a/ext/curl/tests/curl_setopt_basic002.phpt +++ b/ext/curl/tests/curl_setopt_basic002.phpt @@ -49,4 +49,3 @@ curl_close($ch); *** Testing curl_setopt with CURLOPT_STDERR string(%d) "%S" string(%d) "%S" - |