add test for 277

This commit is contained in:
Leo Horie 2014-09-25 13:04:05 -04:00
parent c87e174d12
commit d250908b27

View file

@ -752,6 +752,17 @@ function testMithril(mock) {
m.render(root, [m("div.green", [m("div")]), m("div.blue")])
return root.childNodes.length == 2
})
test(function() {
//https://github.com/lhorie/mithril.js/issues/277
var root = mock.document.createElement("div")
function Field() {
this.tag = "div";
this.attrs = {};
this.children = "hello";
}
m.render(root, new Field())
return root.childNodes.length == 1
})
//end m.render
//m.redraw