Skip to content

Commit 5f5ff92

Browse files
dejalatelesmalyshev
authored andcommitted
Adds 2 new xml files which include the dtd path relative to the base directory for the php source code.
It fixs the fail on the load of the dtd in the tests modified by this commit.
1 parent 24f3693 commit 5f5ff92

File tree

5 files changed

+33
-4
lines changed

5 files changed

+33
-4
lines changed

ext/dom/tests/DOMDocument_loadXML_variation1.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ assert.bail=true
1313
--SKIPIF--
1414
<?php include('skipif.inc'); ?>
1515
--ENV--
16-
XML_FILE=/book_with_dtd.xml
16+
XML_FILE=/book_with_dtd2.xml
1717
LOAD_OPTIONS=LIBXML_DTDLOAD
1818
EXPECTED_RESULT=1
1919
--FILE_EXTERNAL--

ext/dom/tests/DOMDocument_loadXML_variation2.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ assert.bail=true
1313
--SKIPIF--
1414
<?php include('skipif.inc'); ?>
1515
--ENV--
16-
XML_FILE=/wrong_book_with_dtd.xml
16+
XML_FILE=/wrong_book_with_dtd2.xml
1717
LOAD_OPTIONS=LIBXML_DTDVALID
1818
EXPECTED_RESULT=1
1919
--FILE_EXTERNAL--

ext/dom/tests/DOMDocument_loadXML_variation4.phpt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,12 +14,12 @@ assert.bail=true
1414
--SKIPIF--
1515
<?php include('skipif.inc'); ?>
1616
--ENV--
17-
XML_FILE=/book_with_dtd.xml
17+
XML_FILE=/book_with_dtd2.xml
1818
LOAD_OPTIONS=LIBXML_DTDATTR|LIBXML_NOCDATA|LIBXML_NOENT|LIBXML_NOBLANKS
1919
EXPECTED_RESULT=1
2020
--FILE_EXTERNAL--
2121
domdocumentloadxml_test_method_savexml.php
2222
--EXPECT--
2323
<?xml version="1.0" encoding="UTF-8"?>
24-
<!DOCTYPE books SYSTEM "books.dtd">
24+
<!DOCTYPE books SYSTEM "ext/dom/tests/books.dtd">
2525
<books><book><title default="default title">The Grapes of Wrath</title><author>John Steinbeck</author></book><book><title default="default title">The Pearl</title><author>John Steinbeck</author></book><book><title default="default title">entity is only for test purposes</title><author>data for test</author></book></books>

ext/dom/tests/book_with_dtd2.xml

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
<?xml version="1.0" encoding="UTF-8" ?>
2+
<!DOCTYPE books SYSTEM "ext/dom/tests/books.dtd">
3+
<books>
4+
<book>
5+
<title>The Grapes of Wrath</title>
6+
<author>John Steinbeck</author>
7+
</book>
8+
<book>
9+
<title>The Pearl</title>
10+
<author>John Steinbeck</author>
11+
</book>
12+
<book>
13+
<title>&entitest;</title>
14+
<author><![CDATA[data for test]]></author>
15+
</book>
16+
</books>
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
<?xml version="1.0" encoding="UTF-8" ?>
2+
<!DOCTYPE books SYSTEM "ext/dom/tests/books.dtd">
3+
<books>
4+
<book>
5+
<title>The Grapes of Wrath</title>
6+
<author>John Steinbeck</author>
7+
<author>John Steinbeck</author>
8+
</book>
9+
<book>
10+
<title>The Pearl</title>
11+
<author>John Steinbeck</author>
12+
</book>
13+
</books>

0 commit comments

Comments
 (0)