min-document
Advanced tools
Comparing version 1.0.2 to 1.0.3
@@ -17,1 +17,5 @@ module.exports = DOMText | ||
} | ||
DOMText.prototype.replaceData = function replaceData(value) { | ||
this.data = value | ||
} |
{ | ||
"name": "min-document", | ||
"version": "1.0.2", | ||
"version": "1.0.3", | ||
"description": "A minimal DOM implementation", | ||
@@ -5,0 +5,0 @@ "keywords": [], |
@@ -33,5 +33,9 @@ var test = require("tape") | ||
assert.equal(frag.nodeType, 11) | ||
var h1 = document.createElement("h1") | ||
var h2 = document.createElement("h2") | ||
assert.equal(h1.nodeType, 1) | ||
assert.equal(h1.nodeType, 1) | ||
@@ -87,1 +91,15 @@ frag.appendChild(h1) | ||
test("can create/manipulate textnodes", function (assert) { | ||
var textnode = document.createTextNode("hello") | ||
assert.equal(textnode.nodeType, 3) | ||
assert.equal(textnode.data, "hello") | ||
assert.equal(typeof textnode.replaceData, "function") | ||
textnode.replaceData("goodbye") | ||
assert.equal(textnode.nodeType, 3) | ||
assert.equal(textnode.data, "goodbye") | ||
assert.equal(typeof textnode.replaceData, "function") | ||
assert.end() | ||
}) |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
14911
310