mirror of
https://github.com/odoo/owl.git
synced 2025-10-06 19:59:41 +07:00
[REF] autoformat some files
This commit is contained in:
committed by
Géry Debongnie
parent
e04c5b1c6b
commit
8ee0973dab
@@ -1554,7 +1554,7 @@ describe("random stuff/miscellaneous", () => {
|
|||||||
</div>`;
|
</div>`;
|
||||||
widgets = { D, E, F };
|
widgets = { D, E, F };
|
||||||
name = "C";
|
name = "C";
|
||||||
state = {flag: true};
|
state = { flag: true };
|
||||||
|
|
||||||
constructor(parent, props) {
|
constructor(parent, props) {
|
||||||
super(parent, props);
|
super(parent, props);
|
||||||
@@ -1618,7 +1618,7 @@ describe("random stuff/miscellaneous", () => {
|
|||||||
"D:mounted",
|
"D:mounted",
|
||||||
"E:mounted",
|
"E:mounted",
|
||||||
"C:mounted",
|
"C:mounted",
|
||||||
"A:mounted",
|
"A:mounted"
|
||||||
]);
|
]);
|
||||||
|
|
||||||
// update
|
// update
|
||||||
@@ -1637,7 +1637,7 @@ describe("random stuff/miscellaneous", () => {
|
|||||||
"C:_patch",
|
"C:_patch",
|
||||||
"E:willUnmount",
|
"E:willUnmount",
|
||||||
"E:destroy",
|
"E:destroy",
|
||||||
"E:destroy", // maybe should look into this
|
"E:destroy", // maybe should look into this
|
||||||
"F:_patch(from _mount)",
|
"F:_patch(from _mount)",
|
||||||
"F:mounted",
|
"F:mounted",
|
||||||
"D:_patch",
|
"D:_patch",
|
||||||
|
|||||||
+6
-4
@@ -748,7 +748,6 @@ describe("foreach", () => {
|
|||||||
expect(console.warn).toHaveBeenCalledTimes(1);
|
expect(console.warn).toHaveBeenCalledTimes(1);
|
||||||
console.warn = consoleWarn;
|
console.warn = consoleWarn;
|
||||||
});
|
});
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
describe("misc", () => {
|
describe("misc", () => {
|
||||||
@@ -982,14 +981,17 @@ describe("t-ref", () => {
|
|||||||
});
|
});
|
||||||
|
|
||||||
test("refs in a loop", () => {
|
test("refs in a loop", () => {
|
||||||
qweb.addTemplate("test", `
|
qweb.addTemplate(
|
||||||
|
"test",
|
||||||
|
`
|
||||||
<div>
|
<div>
|
||||||
<t t-foreach="items" t-as="item">
|
<t t-foreach="items" t-as="item">
|
||||||
<div t-ref="item" t-key="item"><t t-esc="item"/></div>
|
<div t-ref="item" t-key="item"><t t-esc="item"/></div>
|
||||||
</t>
|
</t>
|
||||||
</div>`);
|
</div>`
|
||||||
|
);
|
||||||
let refs: any = {};
|
let refs: any = {};
|
||||||
renderToDOM(qweb, "test", { refs, items: [1,2,3] });
|
renderToDOM(qweb, "test", { refs, items: [1, 2, 3] });
|
||||||
expect(Object.keys(refs)).toEqual(["1", "2", "3"]);
|
expect(Object.keys(refs)).toEqual(["1", "2", "3"]);
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user