From fca1501ed6ab2018cc114899fe8fc1f203befb6b Mon Sep 17 00:00:00 2001 From: Anatol Belski Date: Tue, 1 Apr 2014 10:08:08 +0200 Subject: [PATCH] added test for bug #53965 --- ext/xsl/tests/53965/collection.xml | 13 +++++++++++++ ext/xsl/tests/53965/collection.xsl | 11 +++++++++++ ext/xsl/tests/53965/include.xsl | 7 +++++++ ext/xsl/tests/bug53965.phpt | 27 +++++++++++++++++++++++++++ 4 files changed, 58 insertions(+) create mode 100644 ext/xsl/tests/53965/collection.xml create mode 100644 ext/xsl/tests/53965/collection.xsl create mode 100644 ext/xsl/tests/53965/include.xsl create mode 100644 ext/xsl/tests/bug53965.phpt diff --git a/ext/xsl/tests/53965/collection.xml b/ext/xsl/tests/53965/collection.xml new file mode 100644 index 0000000000..a3039cd101 --- /dev/null +++ b/ext/xsl/tests/53965/collection.xml @@ -0,0 +1,13 @@ + + + + Fight for your mind + Ben Harper + 1995 + + + Electric Ladyland + Jimi Hendrix + 1997 + + \ No newline at end of file diff --git a/ext/xsl/tests/53965/collection.xsl b/ext/xsl/tests/53965/collection.xsl new file mode 100644 index 0000000000..5474f863ec --- /dev/null +++ b/ext/xsl/tests/53965/collection.xsl @@ -0,0 +1,11 @@ + + + + + + + + Hey! Welcome to 's sweet CD collection! + + + \ No newline at end of file diff --git a/ext/xsl/tests/53965/include.xsl b/ext/xsl/tests/53965/include.xsl new file mode 100644 index 0000000000..4a01296705 --- /dev/null +++ b/ext/xsl/tests/53965/include.xsl @@ -0,0 +1,7 @@ + + +

+

by -

+
+
+
\ No newline at end of file diff --git a/ext/xsl/tests/bug53965.phpt b/ext/xsl/tests/bug53965.phpt new file mode 100644 index 0000000000..8de777ed63 --- /dev/null +++ b/ext/xsl/tests/bug53965.phpt @@ -0,0 +1,27 @@ +--TEST-- +Bug #53965 ( cannot find files with relative paths when loaded with "file://") +--SKIPIF-- + +--FILE-- +load($base . DIRECTORY_SEPARATOR . 'collection.xml'); + +$xsl = new DOMDocument(); +$xsl->load($base . DIRECTORY_SEPARATOR . 'collection.xsl'); + +$proc = new XSLTProcessor; +$proc->importStyleSheet($xsl); + +echo $proc->transformToXML($xml); +?> +--EXPECTF-- +Hey! Welcome to Nicolas Eliaszewicz's sweet CD collection! + +

Fight for your mind

by Ben Harper - 1995


+

Electric Ladyland

by Jimi Hendrix - 1997


-- 2.40.0