Files
odoo_source/addons/bus
tsm-odoo e9446a511e [FIX] bus: fix race in websocket tests
Before this commit, websocket tests were sometimes failing with the
`no result to fetch` error. This is due to a race between the
`subscribe` event being received which itself leads to dispatching bus
notifications interferring with the rest of the test (the connection
is shared).

In order to solve this issue, the `WebsocketCase` now exposes a
`subscribe` method that waits for this dispatching to be done in order
to ensure it will not interfere with the rest of the test.

Some tests were also failing because the subscription was done with 0
as the last notification id. This is an issue since this could lead to
notifications being sent while they are not expected.

In order to solve this issue, `last_notification_id` is now correctly
passed when subscribing to channel notifications.

fixes runbot-24226

closes odoo/odoo#138649

X-original-commit: 3256885fd08d33a67d7165fa33d373fd039ef7af
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
Signed-off-by: Matthieu Stockbauer (tsm) <tsm@odoo.com>
2023-10-14 02:26:53 +00:00
..
…
2023-09-08 16:47:56 +00:00