[FIX] blockdom: toString method in multi could crash

This commit is contained in:
Géry Debongnie
2022-01-17 13:51:50 +01:00
committed by aab-odoo
parent 79a51f2317
commit 7ba0c9f8ba
4 changed files with 44 additions and 1 deletions
+5
View File
@@ -77,6 +77,11 @@ describe("multi blocks", () => {
expect(fixture.innerHTML).toBe("ab");
});
test("multi vnode can be used as text", () => {
mount(text(multi([text("a"), undefined]) as any), fixture);
expect(fixture.innerHTML).toBe("a");
});
test("multi inside a block", async () => {
const block = createBlock("<div><block-child-0/></div>");
const tree = block([], [multi([text("foo"), text("bar")])]);