[FIX] qweb: properly handle xml comments

This commit is contained in:
Géry Debongnie
2019-10-15 13:41:18 +02:00
committed by aab-odoo
parent d40ff53f5a
commit 2825a5a55d
4 changed files with 17 additions and 9 deletions
+2 -2
View File
@@ -50,9 +50,9 @@ describe("static templates", () => {
expect(renderToString(qweb, "test")).toBe("<div><span>word</span></div>");
});
test("ignore comments", () => {
test("properly handle comments", () => {
qweb.addTemplate("test", "<div>hello <!-- comment-->owl</div>");
expect(renderToString(qweb, "test")).toBe("<div>hello owl</div>");
expect(renderToString(qweb, "test")).toBe("<div>hello <!-- comment-->owl</div>");
});
});