moved test to proper file
This commit is contained in:
parent
2793853426
commit
1d3af9d690
2 changed files with 12 additions and 13 deletions
|
|
@ -1549,5 +1549,17 @@ describe("m.render()", function () {
|
|||
expect(root.childNodes[0].innerHTML)
|
||||
.to.equal('<option value="">aaa</option>')
|
||||
})
|
||||
|
||||
it("caches children of editable on update", function () {
|
||||
var root = document.createElement("span")
|
||||
var t1 = m.trust("<h1>fo</h1>o")
|
||||
var t2 = "foo"
|
||||
|
||||
m.render(root, m("span", {contenteditable: false}, t1))
|
||||
m.render(root, m("span", {contenteditable: true}, t2))
|
||||
m.render(root, m("span", {contenteditable: false}, t1))
|
||||
|
||||
expect(root.childNodes[0].innerHTML).to.equal(t1.valueOf())
|
||||
})
|
||||
})
|
||||
})
|
||||
|
|
|
|||
|
|
@ -64,18 +64,5 @@ describe("m.trust()", function () {
|
|||
expect(root.innerHTML).to.equal("<div><p>&copy;</p><p>©</p>©</div>")
|
||||
})
|
||||
|
||||
// not sure that this goes here; not really an m.trust issue
|
||||
it("caches children of editable on update", function () {
|
||||
var root = document.createElement("table")
|
||||
var t1 = m.trust("<h1>fo</h1>o")
|
||||
var t2 = "foo"
|
||||
|
||||
m.render(root, m("span", {contenteditable: false}, t1))
|
||||
m.render(root, m("span", {contenteditable: true}, t2))
|
||||
m.render(root, m("span", {contenteditable: false}, t1))
|
||||
|
||||
expect(root.childNodes[0].innerHTML).to.equal(t1.valueOf())
|
||||
})
|
||||
|
||||
})
|
||||
})
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue