aboutsummaryrefslogtreecommitdiff
path: root/test/xml/external_entity_ignored.t.js
blob: 88b192f2510c1672e9f1f8dbe6653888672425db (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
/*---
includes: [compatNjs.js]
flags: []
paths: []
---*/

import xml from 'xml';

let data = `<?xml version="1.0"?>
<!DOCTYPE foo [
<!ENTITY c PUBLIC "bar" "extern_entity.txt">
]>
<root>&c;</root>
`;

if (has_njs()) {
    let doc = xml.parse(data);
    assert.sameValue(doc.$root.$text, "");
}