summaryrefslogtreecommitdiff
path: root/ext/simplexml
diff options
context:
space:
mode:
authorPeter Kokot <peterkokot@gmail.com>2018-10-15 04:33:09 +0200
committerPeter Kokot <peterkokot@gmail.com>2018-10-15 04:33:09 +0200
commitd679f02295ea079338f029b7f5f4cb65b37f190c (patch)
tree53c519e1f829913a54d9dcea004721a3714cea26 /ext/simplexml
parente84662c35cffaa95ead4322bfe9d61815c185722 (diff)
downloadphp-git-d679f02295ea079338f029b7f5f4cb65b37f190c.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/simplexml')
-rw-r--r--ext/simplexml/tests/012.phpt1
-rw-r--r--ext/simplexml/tests/018.phpt2
-rw-r--r--ext/simplexml/tests/SimpleXMLElement_addAttribute_basic.phpt2
-rw-r--r--ext/simplexml/tests/SimpleXMLElement_addAttribute_required_attribute_name.phpt1
-rw-r--r--ext/simplexml/tests/bug41175.phpt2
-rw-r--r--ext/simplexml/tests/bug42369.phpt2
-rw-r--r--ext/simplexml/tests/bug43221.phpt2
-rw-r--r--ext/simplexml/tests/bug44478.phpt2
-rw-r--r--ext/simplexml/tests/bug45553.phpt2
-rw-r--r--ext/simplexml/tests/bug46003.phpt2
-rw-r--r--ext/simplexml/tests/bug46047.phpt2
-rw-r--r--ext/simplexml/tests/bug62639.phpt2
-rw-r--r--ext/simplexml/tests/feature55218.phpt2
-rw-r--r--ext/simplexml/tests/profile09.phpt1
-rw-r--r--ext/simplexml/tests/simplexml_load_file.phpt2
-rw-r--r--ext/simplexml/tests/sxe_003.phpt1
16 files changed, 12 insertions, 16 deletions
diff --git a/ext/simplexml/tests/012.phpt b/ext/simplexml/tests/012.phpt
index 598aa3c17a..b687b71988 100644
--- a/ext/simplexml/tests/012.phpt
+++ b/ext/simplexml/tests/012.phpt
@@ -30,7 +30,6 @@ __HALT_COMPILER();
?>
===DONE===
--EXPECTF--
-
Warning: main(): Cannot write or create unnamed attribute in %s012.php on line %d
<?xml version="1.0" encoding="ISO-8859-1"?>
<foo attr="value"/>
diff --git a/ext/simplexml/tests/018.phpt b/ext/simplexml/tests/018.phpt
index 41a6f8259c..b6b07d4d39 100644
--- a/ext/simplexml/tests/018.phpt
+++ b/ext/simplexml/tests/018.phpt
@@ -62,4 +62,4 @@ echo "---Done---\n";
<child>
</child>
</person>
----Done--- \ No newline at end of file
+---Done---
diff --git a/ext/simplexml/tests/SimpleXMLElement_addAttribute_basic.phpt b/ext/simplexml/tests/SimpleXMLElement_addAttribute_basic.phpt
index 5cdb88e09a..aedd5978b7 100644
--- a/ext/simplexml/tests/SimpleXMLElement_addAttribute_basic.phpt
+++ b/ext/simplexml/tests/SimpleXMLElement_addAttribute_basic.phpt
@@ -18,4 +18,4 @@ object(SimpleXMLElement)#2 (1) {
string(6) "novels"
}
}
-Done \ No newline at end of file
+Done
diff --git a/ext/simplexml/tests/SimpleXMLElement_addAttribute_required_attribute_name.phpt b/ext/simplexml/tests/SimpleXMLElement_addAttribute_required_attribute_name.phpt
index 22ea4488e6..34e2e68319 100644
--- a/ext/simplexml/tests/SimpleXMLElement_addAttribute_required_attribute_name.phpt
+++ b/ext/simplexml/tests/SimpleXMLElement_addAttribute_required_attribute_name.phpt
@@ -15,4 +15,3 @@ echo $a->asXML();
Warning: SimpleXMLElement::addAttribute(): Attribute name is required in %s on line %d
<?xml version="1.0"?>
<php>testfest</php>
-
diff --git a/ext/simplexml/tests/bug41175.phpt b/ext/simplexml/tests/bug41175.phpt
index 432f217b16..ae0204e05a 100644
--- a/ext/simplexml/tests/bug41175.phpt
+++ b/ext/simplexml/tests/bug41175.phpt
@@ -15,4 +15,4 @@ echo $xml->asXML();
--EXPECT--
<?xml version="1.0"?>
<img src="foo" alt=""/>
-===DONE=== \ No newline at end of file
+===DONE===
diff --git a/ext/simplexml/tests/bug42369.phpt b/ext/simplexml/tests/bug42369.phpt
index e186770033..f8e030526c 100644
--- a/ext/simplexml/tests/bug42369.phpt
+++ b/ext/simplexml/tests/bug42369.phpt
@@ -22,4 +22,4 @@ Bug #42369 (Implicit conversion to string leaks memory)
--EXPECT--
explicit conversion
no conversion
-===DONE=== \ No newline at end of file
+===DONE===
diff --git a/ext/simplexml/tests/bug43221.phpt b/ext/simplexml/tests/bug43221.phpt
index 53b6efdccd..bac2277597 100644
--- a/ext/simplexml/tests/bug43221.phpt
+++ b/ext/simplexml/tests/bug43221.phpt
@@ -17,4 +17,4 @@ Warning: SimpleXMLElement::addAttribute(): Attribute requires prefix for namespa
<?xml version="1.0" encoding="utf-8"?>
<root><node xmlns:foo="http://bar.com" a="b" foo:e="f">value</node></root>
===DONE===
- \ No newline at end of file
+
diff --git a/ext/simplexml/tests/bug44478.phpt b/ext/simplexml/tests/bug44478.phpt
index 377754f792..34630593f8 100644
--- a/ext/simplexml/tests/bug44478.phpt
+++ b/ext/simplexml/tests/bug44478.phpt
@@ -26,4 +26,4 @@ a & b
<?xml version="1.0"?>
<root><node1>a &amp;#38; b</node1><node2>a &amp; b</node2></root>
===DONE===
- \ No newline at end of file
+
diff --git a/ext/simplexml/tests/bug45553.phpt b/ext/simplexml/tests/bug45553.phpt
index 6634498556..9147fdaba1 100644
--- a/ext/simplexml/tests/bug45553.phpt
+++ b/ext/simplexml/tests/bug45553.phpt
@@ -33,4 +33,4 @@ I am a:A
I am a:Nothing
I am Nothing
===DONE===
- \ No newline at end of file
+
diff --git a/ext/simplexml/tests/bug46003.phpt b/ext/simplexml/tests/bug46003.phpt
index e21a4ce742..1a67c6e9ee 100644
--- a/ext/simplexml/tests/bug46003.phpt
+++ b/ext/simplexml/tests/bug46003.phpt
@@ -32,4 +32,4 @@ bool(false)
bool(false)
bool(true)
===DONE===
- \ No newline at end of file
+
diff --git a/ext/simplexml/tests/bug46047.phpt b/ext/simplexml/tests/bug46047.phpt
index 59d14b09c0..921da30bd1 100644
--- a/ext/simplexml/tests/bug46047.phpt
+++ b/ext/simplexml/tests/bug46047.phpt
@@ -50,4 +50,4 @@ SimpleXMLElement Object
)
===DONE===
- \ No newline at end of file
+
diff --git a/ext/simplexml/tests/bug62639.phpt b/ext/simplexml/tests/bug62639.phpt
index 4a4e157b76..8d161836c3 100644
--- a/ext/simplexml/tests/bug62639.phpt
+++ b/ext/simplexml/tests/bug62639.phpt
@@ -60,4 +60,4 @@ object(A)#3 (2) {
}
[0]=>
string(10) "Some Value"
-} \ No newline at end of file
+}
diff --git a/ext/simplexml/tests/feature55218.phpt b/ext/simplexml/tests/feature55218.phpt
index c5b09b4fb8..5aac70ea2a 100644
--- a/ext/simplexml/tests/feature55218.phpt
+++ b/ext/simplexml/tests/feature55218.phpt
@@ -114,4 +114,4 @@ array(1) {
}
array(0) {
}
-===DONE=== \ No newline at end of file
+===DONE===
diff --git a/ext/simplexml/tests/profile09.phpt b/ext/simplexml/tests/profile09.phpt
index 714572df1e..627ad20b8f 100644
--- a/ext/simplexml/tests/profile09.phpt
+++ b/ext/simplexml/tests/profile09.phpt
@@ -15,5 +15,4 @@ echo $root->child;
echo "\n---Done---\n";
?>
--EXPECT--
-
---Done---
diff --git a/ext/simplexml/tests/simplexml_load_file.phpt b/ext/simplexml/tests/simplexml_load_file.phpt
index db4f3d115a..91543979f4 100644
--- a/ext/simplexml/tests/simplexml_load_file.phpt
+++ b/ext/simplexml/tests/simplexml_load_file.phpt
@@ -29,4 +29,4 @@ object(SimpleXMLElement)#1 (1) {
}
}
}
-Done \ No newline at end of file
+Done
diff --git a/ext/simplexml/tests/sxe_003.phpt b/ext/simplexml/tests/sxe_003.phpt
index 583242a61e..f3a2e5c5bc 100644
--- a/ext/simplexml/tests/sxe_003.phpt
+++ b/ext/simplexml/tests/sxe_003.phpt
@@ -59,7 +59,6 @@ for ($sxe->rewind(); $sxe->valid(); $sxe->next()) {
?>
===DONE===
--EXPECTF--
-
Warning: Invalid argument supplied for foreach() in %ssxe_003.php on line %d
===RESET===
bool(true)