Daily updates from Odoo
Friday, March 29, 2024
2 changes · saas-17.2
Enhancements to existing features
This update improves Odoo's internal JavaScript testing tools and test reliability, especially around the HOOT framework used by developers. It helps make automated tests easier to maintain, clearer to diagnose, and less prone to random failures, with limited direct impact on day-to-day business users.
Original PR description
Part 1: https://github.com/odoo/odoo/pull/152930 Part 2: https://github.com/odoo/odoo/pull/153018 Part 3: https://github.com/odoo/odoo/pull/153023 Part 4: https://github.com/odoo/odoo/pull/153203…
Part 1: https://github.com/odoo/odoo/pull/152930 Part 2: https://github.com/odoo/odoo/pull/153018 Part 3: https://github.com/odoo/odoo/pull/153023 Part 4: https://github.com/odoo/odoo/pull/153203 Part 5: https://github.com/odoo/odoo/pull/153425 Part 6: https://github.com/odoo/odoo/pull/153700 Part 7: https://github.com/odoo/odoo/pull/154054 Part 8: https://github.com/odoo/odoo/pull/154579 Part 9: https://github.com/odoo/odoo/pull/155073 Part 10: https://github.com/odoo/odoo/pull/155639 Part 11: https://github.com/odoo/odoo/pull/156255 / https://github.com/odoo/enterprise/pull/58135 Part 12: https://github.com/odoo/odoo/pull/156869 Part 13: https://github.com/odoo/odoo/pull/158384 / https://github.com/odoo/enterprise/pull/59019 Enterprise: https://github.com/odoo/enterprise/pull/59291 This pull requests brings various improvements and fixes to Hoot and the Odoo unit test ecosystem. See the different commit messages for more details. Note: these changes are made in stable to avoid having to support multiple versions of the HOOT API. As such, these changes are intended to be strictly limited to unit tests as to not put the rest of the code base at risk. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update adds better internal testing tools for validating generated page markup in Odoo's web module. It helps developers write clearer and more reliable tests, reducing the risk of display-related regressions reaching users.
Original PR description
This commit adds new matchers in hoot, which allow to test the inner/outerHTML of a node with a string (exact matching) or regex. In the case of a string, both the inner/outerHTML of the given node and the expected string are formatted, s.t. we can indent the expected value as we wish. This commit also adds a web test helper: expectMarkup. It allows to test the equality of two strings enconding html/xml. This is especially useful for view compilers. Again, the values are formatted before being compared. Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr