Wednesday, June 19, 2024
2 changes · saas-17.2
Resolved issues and error corrections
This fixes an error that could occur when checking access to Belgian 281.50 partner tags. The update keeps the existing protection working correctly after a platform change, preventing interruptions for users managing Belgian reporting data.
Original PR description
In 17.0, a protection was added to the 281.50 tags on the partners (commit: 09439b46cbb8b6ef2447d67e1647cbc284d0e192). The code was forward ported but the function `user_has_groups` has been removed in saas-17.2 (in https://github.com/odoo/odoo/commit/cb31d4352c741a5f8a927a65debb8e027e87df22), causing a traceback. In this commit, we rather use the `has_group` function. task-3955109
This fix makes Odoo's web test runner handle errors in test setup and cleanup steps correctly. Instead of freezing until a timeout, failed test preparation is now reported against the right tests, helping development teams identify issues faster and keep test runs reliable.
Original PR description
Before this PR, throwing an error in any test hook (before, after, beforeEach, etc.) would cause the error to be logged but the test would actually timeout because the runner would freeze. This was due to the runner incorrectly catching errors in hooks. This PR ensures that all these callbacks are properly catched to ensure the errors are assigned to each relevant test and do not clog up the runner's execution. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr