[FIX] viin_ai_approval,viin_ai_ops: suppress force-sent approver mail in routing tests
Runbot marks a build FAILED when the captured test log contains any ERROR
record (odoo lower_logging -> result.had_error_log), even with 0 assertion
failures. Three new test classes drive the real approval-routing path
(action_route -> _submit_to_approval -> request.action_confirm), which
message_post()s an approver notification that is force-sent synchronously.
The tests create fresh res.company / users with no email and run without a
mail.catchall.domain ICP, so the send has no sender address and mail_mail
logs 'failed sending mail ... mail.catchall.domain' at ERROR (20 records),
tripping the Runbot gate although every assertion passes.
These tests assert routing / state / counts / multi-company isolation, NOT
email delivery, so set mail_notify_force_send=False on the class env in
setUpClass: the notification mail stays queued (never synchronously sent in
the test transaction) so no spurious error is logged. Inherited by every
sub-env (all build from self.env.context), so it reaches the message_post
inside action_route().
Affected: TestCockpitPendingApprovalsProvider, TestMultiCompanyApprovalRouting
(viin_ai_approval), TestOpsCockpitAggregation (viin_ai_ops).
Verified locally (fresh DB, no catchall): 20 -> 0 'failed sending mail'
ERROR records, 0 ERROR-level logs, full viin_ai_approval+viin_ai_ops suite
0 failed / 0 error of 85 tests.
| Subbuilds | Name | State | Detail |
|---|---|---|---|
| Build 385540 | Check the quality with Pylint: from test_lint to test_pylint 15m | Succeed | Log |
| Build 385541 | At install tests: from account to website_twitter 119m | Succeed | Log |
| Build 385542 | Post install tests: step install all modules 69m | Succeed | Log |
| Build 385543 | Post install tests: from account to payment_asiapay 110m | Succeed | Log |
| Build 385544 | Post install tests: from payment_authorize to test_website_slides_full 124m | Succeed | Log |
| Build 385545 | Post install tests: from test_xlsx_export to to_website_docs_odoo_data 54m | Succeed | Log |
| Build 385546 | Post install tests: from to_website_odoo_version to viin_estimate 59m | Succeed | Log |
| Build 385547 | Post install tests: from viin_estimate_approval to viin_pricelist_validity_advance 24m | Failed | Log |
| Build 385548 | Post install tests: from viin_product_multi_barcodes to website_twitter 39m | Succeed | Log |
| Build 385549 | Test install all modules without demo data: from account to website_twitter 54m | Succeed | Log |
| Create Date | Level | Message |
|---|---|---|
| 06/14/2026 02:10:16 | INFO |
Updated repository Viindoo-odoo
|
| 06/14/2026 02:10:16 | INFO |
Updated repository Viindoo-tvtmaaddons
|
| 06/14/2026 02:10:16 | INFO |
Updated repository Viindoo-erponline-enterprise
|
| 06/14/2026 02:10:16 | INFO |
Updated repository Viindoo-branding
|
| 06/14/2026 02:10:16 | INFO |
Cloned repository Viindoo-ai
|
| 06/14/2026 03:45:33 | ERROR |
Subbuild # 385547:
odoo.addons.viin_helpdesk_project.tests.test_access_rights: ERROR: TestAccessTicket.test_user_who_following_task_or_project_read_ticket
Traceback (most recent call last):
File "/data/build/Viindoo-tvtmaaddons-17.0/viin_helpdesk_project/tests/test_access_rights.py", line 13, in test_user_who_following_task_or_project_read_ticket
ticket = self.env['viin.helpdesk.ticket'].with_user(self.env.ref('base.user_admin')).create({
File "<decorator-gen-1794>", line 2, in create
File "/data/build/Viindoo-odoo-17.0/odoo/api.py", line 430, in _model_create_multi
return create(self, [arg])
File "/data/build/Viindoo-tvtmaaddons-17.0/viin_helpdesk/models/helpdesk_ticket.py", line 336, in create
vals['stage_id'] = team.stage_ids[:1].id
File "/data/build/Viindoo-odoo-17.0/odoo/fields.py", line 2940, in __get__
return super().__get__(records, owner)
File "/data/build/Viindoo-odoo-17.0/odoo/fields.py", line 1182, in __get__
recs._fetch_field(self)
File "/data/build/Viindoo-odoo-17.0/odoo/models.py", line 3824, in _fetch_field
self.fetch(fnames)
File "/data/build/Viindoo-odoo-17.0/odoo/models.py", line 3863, in fetch
self.check_access_rule('read')
File "/data/build/Viindoo-odoo-17.0/odoo/models.py", line 4169, in check_access_rule
raise self.env['ir.rule']._make_access_error(operation, forbidden)
odoo.exceptions.AccessError: Uh-oh! Looks like you have stumbled upon some top-secret records.
Sorry, Mitchell Admin (id=2) doesn't have 'read' access to:
- Helpdesk Team (viin.helpdesk.team)
If you really, really need access, perhaps you can win over your friendly administrator with a batch of freshly baked cookies.
|
| 06/14/2026 03:45:33 | ERROR |
Subbuild # 385547:
odoo.tests.result: 0 failed, 1 error(s) of 1579 tests when loading database 'rb-4e9c1d2-222173-385547'
|