pike.git / lib / modules / Parser.pmod / XML.pmod / testsuite.in

version» Context lines:

pike.git/lib/modules/Parser.pmod/XML.pmod/testsuite.in:354:   array args = ({    "xmlns:soap='http://schemas.xmlsoap.org/soap/envelope/'",    "xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'",    "xmlns:xsd='http://www.w3.org/2001/XMLSchema'",    "xmlns:soapenc='http://schemas.xmlsoap.org/soap/encoding/'",    "soap:encodingStyle='http://schemas.xmlsoap.org/soap/encoding/'" });   for(int i; i<120; i++)    Parser.XML.NSTree.parse_input("<soap:Envelope "+Array.permute(args,i)*" "+"/>");   ]])    + define(nstree_eq,[[ + test_any([[ + object x=Parser.XML.NSTree.parse_input($1); + return (string)x; + ]],$2) + ]])    -  + nstree_eq("<a:foo xmlns:a='ns-one'><b:foo xmlns:b='ns-two'/></a:foo>", + "<a:foo xmlns:a='ns-one' xmlns:b='ns-two'><b:foo/></a:foo>") +  + nstree_eq("<a:foo xmlns:a='ns-one'><foo xmlns='ns-two'/></a:foo>", + "<a:foo xmlns:a='ns-one'><foo xmlns='ns-two'/></a:foo>") +  + dnl nstree_eq("<a:foo xmlns:a='ns-one' xmlns:b='ns-one'><b:foo/></a:foo>", + dnl "<a:foo xmlns:a='ns-one' xmlns:b='ns-one'><b:foo/></a:foo>") +  +    // Simple      test_do([[Parser.XML.Simple()->parse("<!DOCTYPE root [\n<!NOTATION JPGformat>\n]>\n", lambda(mixed ...args){} )]])   test_do([[Parser.XML.Simple()->parse_dtd("%hej;\n", lambda(mixed ... args){}, 1, 2, 3)]])      test_any([[    string error;    object o = Parser.XML.Simple();    o->compat_allow_errors (0);    o->parse("<a></a><foo/>",