Daily updates from Odoo
Friday, July 18, 2025
1 change · saas-18.3
Code cleanup and technical improvements
This update makes internal Web Studio test checks wait for the exact page elements they need before continuing. It reduces random test failures, helping the team validate changes more reliably without affecting end users.
Original PR description
In this commit, we simplify the assertions made in run functions with more explicit triggers that use Hoot's pseudo-selectors. This is almost the same thing, except that the macro system waits to…
In this commit, we simplify the assertions made in run functions with more explicit triggers that use Hoot's pseudo-selectors. This is almost the same thing, except that the macro system waits to find the trigger (animationFrame by animationFrame). If, for some reason, the parent element already exists but not the child element sought in the run function, then the tour spits out... indeterministically.
So this commit can also fix tours.
For example:
{
trigger: ".o-web-studio-report-container :iframe body",
run() {
assertEqual(
this.anchor.querySelector(".test-added-0").textContent,
"in document view"
);
assertEqual(this.anchor.querySelector(".test-added-1").textContent, "in main view");
},
},
:iframe body is present but not ".test-added-0" yet ... then the assertion failed when it is enough just to wait for the element to be in the dom.
Is fixed with :
{
trigger: ".o-web-studio-report-container :iframe body .test-added-0:contains(in document view)",
},
{
trigger: ".o-web-studio-report-container :iframe body .test-added-1:contains(in main view)",
}