From cf565652c69536c1501e4f6a15a3a11b92ee171f Mon Sep 17 00:00:00 2001 From: Christophe Monniez Date: Fri, 3 Feb 2023 15:21:33 +0000 Subject: [PATCH] [FIX] website_sale: wait for the editor to be loaded As the tour `shop_editor` is very small, it finishes before the editor itself is fully loaded. As a consequence, some threads are remaining on the server side and can lead to a complete failure of the test. This seems to particularly affects builds on Bookwork with werkzeug 2.2.2 and python 3.11 as it leads to werkzeug requests timeout. With this commit, a step is added at the beginning of the test to ensure that the editor is loaded before beginning the test by itself. closes odoo/odoo#112698 Signed-off-by: William Braeckman (wbr) Signed-off-by: Christophe Monniez (moc) --- .../static/tests/tours/website_sale_shop_editor_tour.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/addons/website_sale/static/tests/tours/website_sale_shop_editor_tour.js b/addons/website_sale/static/tests/tours/website_sale_shop_editor_tour.js index f93c86597f8..9004498c604 100644 --- a/addons/website_sale/static/tests/tours/website_sale_shop_editor_tour.js +++ b/addons/website_sale/static/tests/tours/website_sale_shop_editor_tour.js @@ -6,6 +6,9 @@ registry.category("web_tour.tours").add('shop_editor', { test: true, url: '/shop?enable_editor=1', steps: [{ + trigger: '#oe_snippets.o_loaded', + content: "Wait for the editor to be loaded" +}, { content: "Click on pricelist dropdown", trigger: "iframe div.o_pricelist_dropdown a[data-bs-toggle=dropdown]", }, {