From b53feba3d006bb1a05eb7ba54217285e3dcf5df0 Mon Sep 17 00:00:00 2001 From: qsm-odoo Date: Tue, 21 Jun 2022 09:56:08 +0000 Subject: [PATCH] [FIX] website: fix typo in snippets_all_drag_and_drop test The test was introduced in [1] with a typo on the first step (which is only there to ensure the test does contain steps). Note: with the 15.1 forward-port, the "number of steps" check had to be adapted because snippets were removed at [2]. This reveals however two issues: - Snippets which use the generic "Dynamic Snippet" as base are not tested by the test. - [2] removed the s_speaker_bio snippet by mistake Both those problems will be fixed in other PR alongside improving the way the "number of steps" check works. [1]: https://github.com/odoo/odoo/commit/460d5ecb926c13a79ba363f8f86442433d91bf6f [2]: https://github.com/odoo/odoo/commit/b5c87d86cad1aa2b44f805da0b2d6635aeb85b96 closes odoo/odoo#94359 X-original-commit: 8e6a6ab532637ef9ef8d87ca4062e26b2852825a Signed-off-by: Quentin Smetz (qsm) --- .../website/static/tests/tours/snippets_all_drag_and_drop.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/website/static/tests/tours/snippets_all_drag_and_drop.js b/addons/website/static/tests/tours/snippets_all_drag_and_drop.js index 513a9a5d182..d39ff4881ff 100644 --- a/addons/website/static/tests/tours/snippets_all_drag_and_drop.js +++ b/addons/website/static/tests/tours/snippets_all_drag_and_drop.js @@ -67,8 +67,8 @@ tour.register("snippets_all_drag_and_drop", { // safety check, otherwise the test might "break" one day and // receive no steps. The test would then not test anything anymore // without us noticing it. - if (steps.lenth < 280) { - console.error("This test is not behaving as it should."); + if (steps.length < 270) { + console.error(`This test is not behaving as it should, got only ${steps.length} steps.`); } }, },