Contributors mailing list archives
contributors@odoo-community.org
Browse archives
Re: Odoo Test framework and rollback issue
by
Tecnativa. S. L., Pedro M. Baeza
Holger Brunn has pointed to me that there's a way to recover properly in SavepointCase tests after a raise:
You have to add the reset_on_failure to your `with` statement. And it seems that since v15, the savepoint is enough.
Anyway, think twice about piling a lot of asserts in the same test, being raise or not, as having an early failure makes you to iterate several times until having a pass one, although testing flows is usual to have that sequential asserts.
Thanks for the extra insights, Holger!
Regards.
Reference
-
Odoo Test framework and rollback issue
byDEC, Yann Papouin- 15/11/2023 18:15:13 - 0-
-
Re: Odoo Test framework and rollback issue
byTecnativa. S. L., Pedro M. Baeza- 17/11/2023 13:39:03 - 0 -
Re: Odoo Test framework and rollback issue
byAcsone SA/NV, Laurent Mignon- 16/11/2023 08:46:01 - 0 -
Re: Odoo Test framework and rollback issue
byTecnativa. S. L., Pedro M. Baeza- 15/11/2023 18:34:58 - 0
-