aboutsummaryrefslogtreecommitdiff
path: root/cordova/node_modules/sax/test
diff options
context:
space:
mode:
Diffstat (limited to 'cordova/node_modules/sax/test')
-rwxr-xr-xcordova/node_modules/sax/test/buffer-overrun.js25
-rwxr-xr-xcordova/node_modules/sax/test/cdata-chunked.js11
-rwxr-xr-xcordova/node_modules/sax/test/cdata-end-split.js15
-rwxr-xr-xcordova/node_modules/sax/test/cdata-fake-end.js28
-rwxr-xr-xcordova/node_modules/sax/test/cdata-multiple.js15
-rwxr-xr-xcordova/node_modules/sax/test/cdata.js10
-rwxr-xr-xcordova/node_modules/sax/test/index.js86
-rwxr-xr-xcordova/node_modules/sax/test/issue-23.js43
-rwxr-xr-xcordova/node_modules/sax/test/issue-30.js24
-rwxr-xr-xcordova/node_modules/sax/test/issue-35.js15
-rwxr-xr-xcordova/node_modules/sax/test/issue-47.js13
-rwxr-xr-xcordova/node_modules/sax/test/issue-49.js31
-rwxr-xr-xcordova/node_modules/sax/test/parser-position.js28
-rwxr-xr-xcordova/node_modules/sax/test/script.js12
-rwxr-xr-xcordova/node_modules/sax/test/self-closing-child-strict.js40
-rwxr-xr-xcordova/node_modules/sax/test/self-closing-child.js40
-rwxr-xr-xcordova/node_modules/sax/test/self-closing-tag.js25
-rwxr-xr-xcordova/node_modules/sax/test/stray-ending.js17
-rwxr-xr-xcordova/node_modules/sax/test/trailing-non-whitespace.js17
-rwxr-xr-xcordova/node_modules/sax/test/unquoted.js17
-rwxr-xr-xcordova/node_modules/sax/test/xmlns-issue-41.js67
-rwxr-xr-xcordova/node_modules/sax/test/xmlns-rebinding.js59
-rwxr-xr-xcordova/node_modules/sax/test/xmlns-strict.js71
-rwxr-xr-xcordova/node_modules/sax/test/xmlns-unbound.js15
-rwxr-xr-xcordova/node_modules/sax/test/xmlns-xml-default-prefix-attribute.js35
-rwxr-xr-xcordova/node_modules/sax/test/xmlns-xml-default-prefix.js20
-rwxr-xr-xcordova/node_modules/sax/test/xmlns-xml-default-redefine.js40
27 files changed, 0 insertions, 819 deletions
diff --git a/cordova/node_modules/sax/test/buffer-overrun.js b/cordova/node_modules/sax/test/buffer-overrun.js
deleted file mode 100755
index 8d12fac..0000000
--- a/cordova/node_modules/sax/test/buffer-overrun.js
+++ /dev/null
@@ -1,25 +0,0 @@
-// set this really low so that I don't have to put 64 MB of xml in here.
-var sax = require("../lib/sax")
-var bl = sax.MAX_BUFFER_LENGTH
-sax.MAX_BUFFER_LENGTH = 5;
-
-require(__dirname).test({
- expect : [
- ["error", "Max buffer length exceeded: tagName\nLine: 0\nColumn: 15\nChar: "],
- ["error", "Max buffer length exceeded: tagName\nLine: 0\nColumn: 30\nChar: "],
- ["error", "Max buffer length exceeded: tagName\nLine: 0\nColumn: 45\nChar: "],
- ["opentag", {
- "name": "ABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZ",
- "attributes": {}
- }],
- ["text", "yo"],
- ["closetag", "ABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZ"]
- ]
-}).write("<abcdefghijklmn")
- .write("opqrstuvwxyzABC")
- .write("DEFGHIJKLMNOPQR")
- .write("STUVWXYZ>")
- .write("yo")
- .write("</abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ>")
- .close();
-sax.MAX_BUFFER_LENGTH = bl
diff --git a/cordova/node_modules/sax/test/cdata-chunked.js b/cordova/node_modules/sax/test/cdata-chunked.js
deleted file mode 100755
index ccd5ee6..0000000
--- a/cordova/node_modules/sax/test/cdata-chunked.js
+++ /dev/null
@@ -1,11 +0,0 @@
-
-require(__dirname).test({
- expect : [
- ["opentag", {"name": "R","attributes": {}}],
- ["opencdata", undefined],
- ["cdata", " this is character data  "],
- ["closecdata", undefined],
- ["closetag", "R"]
- ]
-}).write("<r><![CDATA[ this is ").write("character data  ").write("]]></r>").close();
-
diff --git a/cordova/node_modules/sax/test/cdata-end-split.js b/cordova/node_modules/sax/test/cdata-end-split.js
deleted file mode 100755
index b41bd00..0000000
--- a/cordova/node_modules/sax/test/cdata-end-split.js
+++ /dev/null
@@ -1,15 +0,0 @@
-
-require(__dirname).test({
- expect : [
- ["opentag", {"name": "R","attributes": {}}],
- ["opencdata", undefined],
- ["cdata", " this is "],
- ["closecdata", undefined],
- ["closetag", "R"]
- ]
-})
- .write("<r><![CDATA[ this is ]")
- .write("]>")
- .write("</r>")
- .close();
-
diff --git a/cordova/node_modules/sax/test/cdata-fake-end.js b/cordova/node_modules/sax/test/cdata-fake-end.js
deleted file mode 100755
index 07aeac4..0000000
--- a/cordova/node_modules/sax/test/cdata-fake-end.js
+++ /dev/null
@@ -1,28 +0,0 @@
-
-var p = require(__dirname).test({
- expect : [
- ["opentag", {"name": "R","attributes": {}}],
- ["opencdata", undefined],
- ["cdata", "[[[[[[[[]]]]]]]]"],
- ["closecdata", undefined],
- ["closetag", "R"]
- ]
-})
-var x = "<r><![CDATA[[[[[[[[[]]]]]]]]]]></r>"
-for (var i = 0; i < x.length ; i ++) {
- p.write(x.charAt(i))
-}
-p.close();
-
-
-var p2 = require(__dirname).test({
- expect : [
- ["opentag", {"name": "R","attributes": {}}],
- ["opencdata", undefined],
- ["cdata", "[[[[[[[[]]]]]]]]"],
- ["closecdata", undefined],
- ["closetag", "R"]
- ]
-})
-var x = "<r><![CDATA[[[[[[[[[]]]]]]]]]]></r>"
-p2.write(x).close();
diff --git a/cordova/node_modules/sax/test/cdata-multiple.js b/cordova/node_modules/sax/test/cdata-multiple.js
deleted file mode 100755
index dab2015..0000000
--- a/cordova/node_modules/sax/test/cdata-multiple.js
+++ /dev/null
@@ -1,15 +0,0 @@
-
-require(__dirname).test({
- expect : [
- ["opentag", {"name": "R","attributes": {}}],
- ["opencdata", undefined],
- ["cdata", " this is "],
- ["closecdata", undefined],
- ["opencdata", undefined],
- ["cdata", "character data  "],
- ["closecdata", undefined],
- ["closetag", "R"]
- ]
-}).write("<r><![CDATA[ this is ]]>").write("<![CDA").write("T").write("A[")
- .write("character data  ").write("]]></r>").close();
-
diff --git a/cordova/node_modules/sax/test/cdata.js b/cordova/node_modules/sax/test/cdata.js
deleted file mode 100755
index 0f09cce..0000000
--- a/cordova/node_modules/sax/test/cdata.js
+++ /dev/null
@@ -1,10 +0,0 @@
-require(__dirname).test({
- xml : "<r><![CDATA[ this is character data  ]]></r>",
- expect : [
- ["opentag", {"name": "R","attributes": {}}],
- ["opencdata", undefined],
- ["cdata", " this is character data  "],
- ["closecdata", undefined],
- ["closetag", "R"]
- ]
-});
diff --git a/cordova/node_modules/sax/test/index.js b/cordova/node_modules/sax/test/index.js
deleted file mode 100755
index d4e1ef4..0000000
--- a/cordova/node_modules/sax/test/index.js
+++ /dev/null
@@ -1,86 +0,0 @@
-var globalsBefore = JSON.stringify(Object.keys(global))
- , util = require("util")
- , assert = require("assert")
- , fs = require("fs")
- , path = require("path")
- , sax = require("../lib/sax")
-
-exports.sax = sax
-
-// handy way to do simple unit tests
-// if the options contains an xml string, it'll be written and the parser closed.
-// otherwise, it's assumed that the test will write and close.
-exports.test = function test (options) {
- var xml = options.xml
- , parser = sax.parser(options.strict, options.opt)
- , expect = options.expect
- , e = 0
- sax.EVENTS.forEach(function (ev) {
- parser["on" + ev] = function (n) {
- if (process.env.DEBUG) {
- console.error({ expect: expect[e]
- , actual: [ev, n] })
- }
- if (e >= expect.length && (ev === "end" || ev === "ready")) return
- assert.ok( e < expect.length,
- "expectation #"+e+" "+util.inspect(expect[e])+"\n"+
- "Unexpected event: "+ev+" "+(n ? util.inspect(n) : ""))
- var inspected = n instanceof Error ? "\n"+ n.message : util.inspect(n)
- assert.equal(ev, expect[e][0],
- "expectation #"+e+"\n"+
- "Didn't get expected event\n"+
- "expect: "+expect[e][0] + " " +util.inspect(expect[e][1])+"\n"+
- "actual: "+ev+" "+inspected+"\n")
- if (ev === "error") assert.equal(n.message, expect[e][1])
- else assert.deepEqual(n, expect[e][1],
- "expectation #"+e+"\n"+
- "Didn't get expected argument\n"+
- "expect: "+expect[e][0] + " " +util.inspect(expect[e][1])+"\n"+
- "actual: "+ev+" "+inspected+"\n")
- e++
- if (ev === "error") parser.resume()
- }
- })
- if (xml) parser.write(xml).close()
- return parser
-}
-
-if (module === require.main) {
- var running = true
- , failures = 0
-
- function fail (file, er) {
- util.error("Failed: "+file)
- util.error(er.stack || er.message)
- failures ++
- }
-
- fs.readdir(__dirname, function (error, files) {
- files = files.filter(function (file) {
- return (/\.js$/.exec(file) && file !== 'index.js')
- })
- var n = files.length
- , i = 0
- console.log("0.." + n)
- files.forEach(function (file) {
- // run this test.
- try {
- require(path.resolve(__dirname, file))
- var globalsAfter = JSON.stringify(Object.keys(global))
- if (globalsAfter !== globalsBefore) {
- var er = new Error("new globals introduced\n"+
- "expected: "+globalsBefore+"\n"+
- "actual: "+globalsAfter)
- globalsBefore = globalsAfter
- throw er
- }
- console.log("ok " + (++i) + " - " + file)
- } catch (er) {
- console.log("not ok "+ (++i) + " - " + file)
- fail(file, er)
- }
- })
- if (!failures) return console.log("#all pass")
- else return console.error(failures + " failure" + (failures > 1 ? "s" : ""))
- })
-}
diff --git a/cordova/node_modules/sax/test/issue-23.js b/cordova/node_modules/sax/test/issue-23.js
deleted file mode 100755
index e7991b2..0000000
--- a/cordova/node_modules/sax/test/issue-23.js
+++ /dev/null
@@ -1,43 +0,0 @@
-
-require(__dirname).test
- ( { xml :
- "<compileClassesResponse>"+
- "<result>"+
- "<bodyCrc>653724009</bodyCrc>"+
- "<column>-1</column>"+
- "<id>01pG0000002KoSUIA0</id>"+
- "<line>-1</line>"+
- "<name>CalendarController</name>"+
- "<success>true</success>"+
- "</result>"+
- "</compileClassesResponse>"
-
- , expect :
- [ [ "opentag", { name: "COMPILECLASSESRESPONSE", attributes: {} } ]
- , [ "opentag", { name : "RESULT", attributes: {} } ]
- , [ "opentag", { name: "BODYCRC", attributes: {} } ]
- , [ "text", "653724009" ]
- , [ "closetag", "BODYCRC" ]
- , [ "opentag", { name: "COLUMN", attributes: {} } ]
- , [ "text", "-1" ]
- , [ "closetag", "COLUMN" ]
- , [ "opentag", { name: "ID", attributes: {} } ]
- , [ "text", "01pG0000002KoSUIA0" ]
- , [ "closetag", "ID" ]
- , [ "opentag", {name: "LINE", attributes: {} } ]
- , [ "text", "-1" ]
- , [ "closetag", "LINE" ]
- , [ "opentag", {name: "NAME", attributes: {} } ]
- , [ "text", "CalendarController" ]
- , [ "closetag", "NAME" ]
- , [ "opentag", {name: "SUCCESS", attributes: {} } ]
- , [ "text", "true" ]
- , [ "closetag", "SUCCESS" ]
- , [ "closetag", "RESULT" ]
- , [ "closetag", "COMPILECLASSESRESPONSE" ]
- ]
- , strict : false
- , opt : {}
- }
- )
-
diff --git a/cordova/node_modules/sax/test/issue-30.js b/cordova/node_modules/sax/test/issue-30.js
deleted file mode 100755
index c2cc809..0000000
--- a/cordova/node_modules/sax/test/issue-30.js
+++ /dev/null
@@ -1,24 +0,0 @@
-// https://github.com/isaacs/sax-js/issues/33
-require(__dirname).test
- ( { xml : "<xml>\n"+
- "<!-- \n"+
- " comment with a single dash- in it\n"+
- "-->\n"+
- "<data/>\n"+
- "</xml>"
-
- , expect :
- [ [ "opentag", { name: "xml", attributes: {} } ]
- , [ "text", "\n" ]
- , [ "comment", " \n comment with a single dash- in it\n" ]
- , [ "text", "\n" ]
- , [ "opentag", { name: "data", attributes: {} } ]
- , [ "closetag", "data" ]
- , [ "text", "\n" ]
- , [ "closetag", "xml" ]
- ]
- , strict : true
- , opt : {}
- }
- )
-
diff --git a/cordova/node_modules/sax/test/issue-35.js b/cordova/node_modules/sax/test/issue-35.js
deleted file mode 100755
index 7c521c5..0000000
--- a/cordova/node_modules/sax/test/issue-35.js
+++ /dev/null
@@ -1,15 +0,0 @@
-// https://github.com/isaacs/sax-js/issues/35
-require(__dirname).test
- ( { xml : "<xml>&#Xd;&#X0d;\n"+
- "</xml>"
-
- , expect :
- [ [ "opentag", { name: "xml", attributes: {} } ]
- , [ "text", "\r\r\n" ]
- , [ "closetag", "xml" ]
- ]
- , strict : true
- , opt : {}
- }
- )
-
diff --git a/cordova/node_modules/sax/test/issue-47.js b/cordova/node_modules/sax/test/issue-47.js
deleted file mode 100755
index 911c7d0..0000000
--- a/cordova/node_modules/sax/test/issue-47.js
+++ /dev/null
@@ -1,13 +0,0 @@
-// https://github.com/isaacs/sax-js/issues/47
-require(__dirname).test
- ( { xml : '<a href="query.svc?x=1&y=2&z=3"/>'
- , expect : [
- [ "attribute", { name:'href', value:"query.svc?x=1&y=2&z=3"} ],
- [ "opentag", { name: "a", attributes: { href:"query.svc?x=1&y=2&z=3"} } ],
- [ "closetag", "a" ]
- ]
- , strict : true
- , opt : {}
- }
- )
-
diff --git a/cordova/node_modules/sax/test/issue-49.js b/cordova/node_modules/sax/test/issue-49.js
deleted file mode 100755
index 2964325..0000000
--- a/cordova/node_modules/sax/test/issue-49.js
+++ /dev/null
@@ -1,31 +0,0 @@
-// https://github.com/isaacs/sax-js/issues/49
-require(__dirname).test
- ( { xml : "<xml><script>hello world</script></xml>"
- , expect :
- [ [ "opentag", { name: "xml", attributes: {} } ]
- , [ "opentag", { name: "script", attributes: {} } ]
- , [ "text", "hello world" ]
- , [ "closetag", "script" ]
- , [ "closetag", "xml" ]
- ]
- , strict : false
- , opt : { lowercasetags: true, noscript: true }
- }
- )
-
-require(__dirname).test
- ( { xml : "<xml><script><![CDATA[hello world]]></script></xml>"
- , expect :
- [ [ "opentag", { name: "xml", attributes: {} } ]
- , [ "opentag", { name: "script", attributes: {} } ]
- , [ "opencdata", undefined ]
- , [ "cdata", "hello world" ]
- , [ "closecdata", undefined ]
- , [ "closetag", "script" ]
- , [ "closetag", "xml" ]
- ]
- , strict : false
- , opt : { lowercasetags: true, noscript: true }
- }
- )
-
diff --git a/cordova/node_modules/sax/test/parser-position.js b/cordova/node_modules/sax/test/parser-position.js
deleted file mode 100755
index e4a68b1..0000000
--- a/cordova/node_modules/sax/test/parser-position.js
+++ /dev/null
@@ -1,28 +0,0 @@
-var sax = require("../lib/sax"),
- assert = require("assert")
-
-function testPosition(chunks, expectedEvents) {
- var parser = sax.parser();
- expectedEvents.forEach(function(expectation) {
- parser['on' + expectation[0]] = function() {
- for (var prop in expectation[1]) {
- assert.equal(parser[prop], expectation[1][prop]);
- }
- }
- });
- chunks.forEach(function(chunk) {
- parser.write(chunk);
- });
-};
-
-testPosition(['<div>abcdefgh</div>'],
- [ ['opentag', { position: 5, startTagPosition: 1 }]
- , ['text', { position: 19, startTagPosition: 14 }]
- , ['closetag', { position: 19, startTagPosition: 14 }]
- ]);
-
-testPosition(['<div>abcde','fgh</div>'],
- [ ['opentag', { position: 5, startTagPosition: 1 }]
- , ['text', { position: 19, startTagPosition: 14 }]
- , ['closetag', { position: 19, startTagPosition: 14 }]
- ]);
diff --git a/cordova/node_modules/sax/test/script.js b/cordova/node_modules/sax/test/script.js
deleted file mode 100755
index 464c051..0000000
--- a/cordova/node_modules/sax/test/script.js
+++ /dev/null
@@ -1,12 +0,0 @@
-require(__dirname).test({
- xml : "<html><head><script>if (1 < 0) { console.log('elo there'); }</script></head></html>",
- expect : [
- ["opentag", {"name": "HTML","attributes": {}}],
- ["opentag", {"name": "HEAD","attributes": {}}],
- ["opentag", {"name": "SCRIPT","attributes": {}}],
- ["script", "if (1 < 0) { console.log('elo there'); }"],
- ["closetag", "SCRIPT"],
- ["closetag", "HEAD"],
- ["closetag", "HTML"]
- ]
-});
diff --git a/cordova/node_modules/sax/test/self-closing-child-strict.js b/cordova/node_modules/sax/test/self-closing-child-strict.js
deleted file mode 100755
index ce9c045..0000000
--- a/cordova/node_modules/sax/test/self-closing-child-strict.js
+++ /dev/null
@@ -1,40 +0,0 @@
-
-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 : {}
-});
-
diff --git a/cordova/node_modules/sax/test/self-closing-child.js b/cordova/node_modules/sax/test/self-closing-child.js
deleted file mode 100755
index bc6b52b..0000000
--- a/cordova/node_modules/sax/test/self-closing-child.js
+++ /dev/null
@@ -1,40 +0,0 @@
-
-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 : false,
- opt : {}
-});
-
diff --git a/cordova/node_modules/sax/test/self-closing-tag.js b/cordova/node_modules/sax/test/self-closing-tag.js
deleted file mode 100755
index b2c5736..0000000
--- a/cordova/node_modules/sax/test/self-closing-tag.js
+++ /dev/null
@@ -1,25 +0,0 @@
-
-require(__dirname).test({
- xml :
- "<root> "+
- "<haha /> "+
- "<haha/> "+
- "<monkey> "+
- "=(|) "+
- "</monkey>"+
- "</root> ",
- expect : [
- ["opentag", {name:"ROOT", attributes:{}}],
- ["opentag", {name:"HAHA", attributes:{}}],
- ["closetag", "HAHA"],
- ["opentag", {name:"HAHA", attributes:{}}],
- ["closetag", "HAHA"],
- // ["opentag", {name:"HAHA", attributes:{}}],
- // ["closetag", "HAHA"],
- ["opentag", {name:"MONKEY", attributes:{}}],
- ["text", "=(|)"],
- ["closetag", "MONKEY"],
- ["closetag", "ROOT"]
- ],
- opt : { trim : true }
-}); \ No newline at end of file
diff --git a/cordova/node_modules/sax/test/stray-ending.js b/cordova/node_modules/sax/test/stray-ending.js
deleted file mode 100755
index 6b0aa7f..0000000
--- a/cordova/node_modules/sax/test/stray-ending.js
+++ /dev/null
@@ -1,17 +0,0 @@
-// stray ending tags should just be ignored in non-strict mode.
-// https://github.com/isaacs/sax-js/issues/32
-require(__dirname).test
- ( { xml :
- "<a><b></c></b></a>"
- , expect :
- [ [ "opentag", { name: "A", attributes: {} } ]
- , [ "opentag", { name: "B", attributes: {} } ]
- , [ "text", "</c>" ]
- , [ "closetag", "B" ]
- , [ "closetag", "A" ]
- ]
- , strict : false
- , opt : {}
- }
- )
-
diff --git a/cordova/node_modules/sax/test/trailing-non-whitespace.js b/cordova/node_modules/sax/test/trailing-non-whitespace.js
deleted file mode 100755
index 3e1fb2e..0000000
--- a/cordova/node_modules/sax/test/trailing-non-whitespace.js
+++ /dev/null
@@ -1,17 +0,0 @@
-
-require(__dirname).test({
- xml : "<span>Welcome,</span> to monkey land",
- expect : [
- ["opentag", {
- "name": "SPAN",
- "attributes": {}
- }],
- ["text", "Welcome,"],
- ["closetag", "SPAN"],
- ["text", " to monkey land"],
- ["end"],
- ["ready"]
- ],
- strict : false,
- opt : {}
-});
diff --git a/cordova/node_modules/sax/test/unquoted.js b/cordova/node_modules/sax/test/unquoted.js
deleted file mode 100755
index 79f1d0b..0000000
--- a/cordova/node_modules/sax/test/unquoted.js
+++ /dev/null
@@ -1,17 +0,0 @@
-// unquoted attributes should be ok in non-strict mode
-// https://github.com/isaacs/sax-js/issues/31
-require(__dirname).test
- ( { xml :
- "<span class=test hello=world></span>"
- , expect :
- [ [ "attribute", { name: "class", value: "test" } ]
- , [ "attribute", { name: "hello", value: "world" } ]
- , [ "opentag", { name: "SPAN",
- attributes: { class: "test", hello: "world" } } ]
- , [ "closetag", "SPAN" ]
- ]
- , strict : false
- , opt : {}
- }
- )
-
diff --git a/cordova/node_modules/sax/test/xmlns-issue-41.js b/cordova/node_modules/sax/test/xmlns-issue-41.js
deleted file mode 100755
index 596d82b..0000000
--- a/cordova/node_modules/sax/test/xmlns-issue-41.js
+++ /dev/null
@@ -1,67 +0,0 @@
-var t = require(__dirname)
-
- , xmls = // should be the same both ways.
- [ "<parent xmlns:a='http://ATTRIBUTE' a:attr='value' />"
- , "<parent a:attr='value' xmlns:a='http://ATTRIBUTE' />" ]
-
- , ex1 =
- [ [ "opennamespace"
- , { prefix: "a"
- , uri: "http://ATTRIBUTE"
- }
- ]
- , [ "attribute"
- , { name: "xmlns:a"
- , value: "http://ATTRIBUTE"
- , prefix: "xmlns"
- , local: "a"
- , uri: "http://www.w3.org/2000/xmlns/"
- }
- ]
- , [ "attribute"
- , { name: "a:attr"
- , local: "attr"
- , prefix: "a"
- , uri: "http://ATTRIBUTE"
- , value: "value"
- }
- ]
- , [ "opentag"
- , { name: "parent"
- , uri: ""
- , prefix: ""
- , local: "parent"
- , attributes:
- { "a:attr":
- { name: "a:attr"
- , local: "attr"
- , prefix: "a"
- , uri: "http://ATTRIBUTE"
- , value: "value"
- }
- , "xmlns:a":
- { name: "xmlns:a"
- , local: "a"
- , prefix: "xmlns"
- , uri: "http://www.w3.org/2000/xmlns/"
- , value: "http://ATTRIBUTE"
- }
- }
- , ns: {"a": "http://ATTRIBUTE"}
- }
- ]
- , ["closetag", "parent"]
- , ["closenamespace", { prefix: "a", uri: "http://ATTRIBUTE" }]
- ]
-
- // swap the order of elements 2 and 1
- , ex2 = [ex1[0], ex1[2], ex1[1]].concat(ex1.slice(3))
- , expected = [ex1, ex2]
-
-xmls.forEach(function (x, i) {
- t.test({ xml: x
- , expect: expected[i]
- , strict: true
- , opt: { xmlns: true }
- })
-})
diff --git a/cordova/node_modules/sax/test/xmlns-rebinding.js b/cordova/node_modules/sax/test/xmlns-rebinding.js
deleted file mode 100755
index f464876..0000000
--- a/cordova/node_modules/sax/test/xmlns-rebinding.js
+++ /dev/null
@@ -1,59 +0,0 @@
-
-require(__dirname).test
- ( { xml :
- "<root xmlns:x='x1' xmlns:y='y1' x:a='x1' y:a='y1'>"+
- "<rebind xmlns:x='x2'>"+
- "<check x:a='x2' y:a='y1'/>"+
- "</rebind>"+
- "<check x:a='x1' y:a='y1'/>"+
- "</root>"
-
- , expect :
- [ [ "opennamespace", { prefix: "x", uri: "x1" } ]
- , [ "opennamespace", { prefix: "y", uri: "y1" } ]
- , [ "attribute", { name: "xmlns:x", value: "x1", uri: "http://www.w3.org/2000/xmlns/", prefix: "xmlns", local: "x" } ]
- , [ "attribute", { name: "xmlns:y", value: "y1", uri: "http://www.w3.org/2000/xmlns/", prefix: "xmlns", local: "y" } ]
- , [ "attribute", { name: "x:a", value: "x1", uri: "x1", prefix: "x", local: "a" } ]
- , [ "attribute", { name: "y:a", value: "y1", uri: "y1", prefix: "y", local: "a" } ]
- , [ "opentag", { name: "root", uri: "", prefix: "", local: "root",
- attributes: { "xmlns:x": { name: "xmlns:x", value: "x1", uri: "http://www.w3.org/2000/xmlns/", prefix: "xmlns", local: "x" }
- , "xmlns:y": { name: "xmlns:y", value: "y1", uri: "http://www.w3.org/2000/xmlns/", prefix: "xmlns", local: "y" }
- , "x:a": { name: "x:a", value: "x1", uri: "x1", prefix: "x", local: "a" }
- , "y:a": { name: "y:a", value: "y1", uri: "y1", prefix: "y", local: "a" } },
- ns: { x: 'x1', y: 'y1' } } ]
-
- , [ "opennamespace", { prefix: "x", uri: "x2" } ]
- , [ "attribute", { name: "xmlns:x", value: "x2", uri: "http://www.w3.org/2000/xmlns/", prefix: "xmlns", local: "x" } ]
- , [ "opentag", { name: "rebind", uri: "", prefix: "", local: "rebind",
- attributes: { "xmlns:x": { name: "xmlns:x", value: "x2", uri: "http://www.w3.org/2000/xmlns/", prefix: "xmlns", local: "x" } },
- ns: { x: 'x2' } } ]
-
- , [ "attribute", { name: "x:a", value: "x2", uri: "x2", prefix: "x", local: "a" } ]
- , [ "attribute", { name: "y:a", value: "y1", uri: "y1", prefix: "y", local: "a" } ]
- , [ "opentag", { name: "check", uri: "", prefix: "", local: "check",
- attributes: { "x:a": { name: "x:a", value: "x2", uri: "x2", prefix: "x", local: "a" }
- , "y:a": { name: "y:a", value: "y1", uri: "y1", prefix: "y", local: "a" } },
- ns: { x: 'x2' } } ]
-
- , [ "closetag", "check" ]
-
- , [ "closetag", "rebind" ]
- , [ "closenamespace", { prefix: "x", uri: "x2" } ]
-
- , [ "attribute", { name: "x:a", value: "x1", uri: "x1", prefix: "x", local: "a" } ]
- , [ "attribute", { name: "y:a", value: "y1", uri: "y1", prefix: "y", local: "a" } ]
- , [ "opentag", { name: "check", uri: "", prefix: "", local: "check",
- attributes: { "x:a": { name: "x:a", value: "x1", uri: "x1", prefix: "x", local: "a" }
- , "y:a": { name: "y:a", value: "y1", uri: "y1", prefix: "y", local: "a" } },
- ns: { x: 'x1', y: 'y1' } } ]
- , [ "closetag", "check" ]
-
- , [ "closetag", "root" ]
- , [ "closenamespace", { prefix: "x", uri: "x1" } ]
- , [ "closenamespace", { prefix: "y", uri: "y1" } ]
- ]
- , strict : true
- , opt : { xmlns: true }
- }
- )
-
diff --git a/cordova/node_modules/sax/test/xmlns-strict.js b/cordova/node_modules/sax/test/xmlns-strict.js
deleted file mode 100755
index 4ad615b..0000000
--- a/cordova/node_modules/sax/test/xmlns-strict.js
+++ /dev/null
@@ -1,71 +0,0 @@
-
-require(__dirname).test
- ( { xml :
- "<root>"+
- "<plain attr='normal'/>"+
- "<ns1 xmlns='uri:default'>"+
- "<plain attr='normal'/>"+
- "</ns1>"+
- "<ns2 xmlns:a='uri:nsa'>"+
- "<plain attr='normal'/>"+
- "<a:ns a:attr='namespaced'/>"+
- "</ns2>"+
- "</root>"
-
- , expect :
- [ [ "opentag", { name: "root", prefix: "", local: "root", uri: "",
- attributes: {}, ns: {} } ]
-
- , [ "attribute", { name: "attr", value: "normal", prefix: "", local: "attr", uri: "" } ]
- , [ "opentag", { name: "plain", prefix: "", local: "plain", uri: "",
- attributes: { "attr": { name: "attr", value: "normal", uri: "", prefix: "", local: "attr", uri: "" } },
- ns: {} } ]
- , [ "closetag", "plain" ]
-
- , [ "opennamespace", { prefix: "", uri: "uri:default" } ]
-
- , [ "attribute", { name: "xmlns", value: "uri:default", prefix: "xmlns", local: "", uri: "http://www.w3.org/2000/xmlns/" } ]
- , [ "opentag", { name: "ns1", prefix: "", local: "ns1", uri: "uri:default",
- attributes: { "xmlns": { name: "xmlns", value: "uri:default", prefix: "xmlns", local: "", uri: "http://www.w3.org/2000/xmlns/" } },
- ns: { "": "uri:default" } } ]
-
- , [ "attribute", { name: "attr", value: "normal", prefix: "", local: "attr", uri: "uri:default" } ]
- , [ "opentag", { name: "plain", prefix: "", local: "plain", uri: "uri:default", ns: { '': 'uri:default' },
- attributes: { "attr": { name: "attr", value: "normal", prefix: "", local: "attr", uri: "uri:default" } } } ]
- , [ "closetag", "plain" ]
-
- , [ "closetag", "ns1" ]
-
- , [ "closenamespace", { prefix: "", uri: "uri:default" } ]
-
- , [ "opennamespace", { prefix: "a", uri: "uri:nsa" } ]
-
- , [ "attribute", { name: "xmlns:a", value: "uri:nsa", prefix: "xmlns", local: "a", uri: "http://www.w3.org/2000/xmlns/" } ]
-
- , [ "opentag", { name: "ns2", prefix: "", local: "ns2", uri: "",
- attributes: { "xmlns:a": { name: "xmlns:a", value: "uri:nsa", prefix: "xmlns", local: "a", uri: "http://www.w3.org/2000/xmlns/" } },
- ns: { a: "uri:nsa" } } ]
-
- , [ "attribute", { name: "attr", value: "normal", prefix: "", local: "attr", uri: "" } ]
- , [ "opentag", { name: "plain", prefix: "", local: "plain", uri: "",
- attributes: { "attr": { name: "attr", value: "normal", prefix: "", local: "attr", uri: "" } },
- ns: { a: 'uri:nsa' } } ]
- , [ "closetag", "plain" ]
-
- , [ "attribute", { name: "a:attr", value: "namespaced", prefix: "a", local: "attr", uri: "uri:nsa" } ]
- , [ "opentag", { name: "a:ns", prefix: "a", local: "ns", uri: "uri:nsa",
- attributes: { "a:attr": { name: "a:attr", value: "namespaced", prefix: "a", local: "attr", uri: "uri:nsa" } },
- ns: { a: 'uri:nsa' } } ]
- , [ "closetag", "a:ns" ]
-
- , [ "closetag", "ns2" ]
-
- , [ "closenamespace", { prefix: "a", uri: "uri:nsa" } ]
-
- , [ "closetag", "root" ]
- ]
- , strict : true
- , opt : { xmlns: true }
- }
- )
-
diff --git a/cordova/node_modules/sax/test/xmlns-unbound.js b/cordova/node_modules/sax/test/xmlns-unbound.js
deleted file mode 100755
index 2944b87..0000000
--- a/cordova/node_modules/sax/test/xmlns-unbound.js
+++ /dev/null
@@ -1,15 +0,0 @@
-
-require(__dirname).test(
- { strict : true
- , opt : { xmlns: true }
- , expect :
- [ ["error", "Unbound namespace prefix: \"unbound\"\nLine: 0\nColumn: 28\nChar: >"]
-
- , [ "attribute", { name: "unbound:attr", value: "value", uri: "unbound", prefix: "unbound", local: "attr" } ]
- , [ "opentag", { name: "root", uri: "", prefix: "", local: "root",
- attributes: { "unbound:attr": { name: "unbound:attr", value: "value", uri: "unbound", prefix: "unbound", local: "attr" } },
- ns: {} } ]
- , [ "closetag", "root" ]
- ]
- }
-).write("<root unbound:attr='value'/>")
diff --git a/cordova/node_modules/sax/test/xmlns-xml-default-prefix-attribute.js b/cordova/node_modules/sax/test/xmlns-xml-default-prefix-attribute.js
deleted file mode 100755
index 16da771..0000000
--- a/cordova/node_modules/sax/test/xmlns-xml-default-prefix-attribute.js
+++ /dev/null
@@ -1,35 +0,0 @@
-require(__dirname).test(
- { xml : "<root xml:lang='en'/>"
- , expect :
- [ [ "attribute"
- , { name: "xml:lang"
- , local: "lang"
- , prefix: "xml"
- , uri: "http://www.w3.org/XML/1998/namespace"
- , value: "en"
- }
- ]
- , [ "opentag"
- , { name: "root"
- , uri: ""
- , prefix: ""
- , local: "root"
- , attributes:
- { "xml:lang":
- { name: "xml:lang"
- , local: "lang"
- , prefix: "xml"
- , uri: "http://www.w3.org/XML/1998/namespace"
- , value: "en"
- }
- }
- , ns: {}
- }
- ]
- , ["closetag", "root"]
- ]
- , strict : true
- , opt : { xmlns: true }
- }
-)
-
diff --git a/cordova/node_modules/sax/test/xmlns-xml-default-prefix.js b/cordova/node_modules/sax/test/xmlns-xml-default-prefix.js
deleted file mode 100755
index 9a1ce1b..0000000
--- a/cordova/node_modules/sax/test/xmlns-xml-default-prefix.js
+++ /dev/null
@@ -1,20 +0,0 @@
-require(__dirname).test(
- { xml : "<xml:root/>"
- , expect :
- [
- [ "opentag"
- , { name: "xml:root"
- , uri: "http://www.w3.org/XML/1998/namespace"
- , prefix: "xml"
- , local: "root"
- , attributes: {}
- , ns: {}
- }
- ]
- , ["closetag", "xml:root"]
- ]
- , strict : true
- , opt : { xmlns: true }
- }
-)
-
diff --git a/cordova/node_modules/sax/test/xmlns-xml-default-redefine.js b/cordova/node_modules/sax/test/xmlns-xml-default-redefine.js
deleted file mode 100755
index 1eba9c7..0000000
--- a/cordova/node_modules/sax/test/xmlns-xml-default-redefine.js
+++ /dev/null
@@ -1,40 +0,0 @@
-require(__dirname).test(
- { xml : "<xml:root xmlns:xml='ERROR'/>"
- , expect :
- [ ["error"
- , "xml: prefix must be bound to http://www.w3.org/XML/1998/namespace\n"
- + "Actual: ERROR\n"
- + "Line: 0\nColumn: 27\nChar: '"
- ]
- , [ "attribute"
- , { name: "xmlns:xml"
- , local: "xml"
- , prefix: "xmlns"
- , uri: "http://www.w3.org/2000/xmlns/"
- , value: "ERROR"
- }
- ]
- , [ "opentag"
- , { name: "xml:root"
- , uri: "http://www.w3.org/XML/1998/namespace"
- , prefix: "xml"
- , local: "root"
- , attributes:
- { "xmlns:xml":
- { name: "xmlns:xml"
- , local: "xml"
- , prefix: "xmlns"
- , uri: "http://www.w3.org/2000/xmlns/"
- , value: "ERROR"
- }
- }
- , ns: {}
- }
- ]
- , ["closetag", "xml:root"]
- ]
- , strict : true
- , opt : { xmlns: true }
- }
-)
-