roar/asciiblaster-cordoba/platforms/android/cordova/node_modules/sax/test/self-closing-child-strict.js

41 lines
648 B
JavaScript

require(__dirname).test({
xml :
"<root>"+
"<child>" +
"<haha />" +
"</child>" +
"<monkey>" +
"=(|)" +
"</monkey>" +
"</root>",
expect : [
["opentag", {
"name": "root",
"attributes": {}
}],
["opentag", {
"name": "child",
"attributes": {}
}],
["opentag", {
"name": "haha",
"attributes": {}
}],
["closetag", "haha"],
["closetag", "child"],
["opentag", {
"name": "monkey",
"attributes": {}
}],
["text", "=(|)"],
["closetag", "monkey"],
["closetag", "root"],
["end"],
["ready"]
],
strict : true,
opt : {}
});