From 533a22189d0444ff6a2da1f7588692e2428cc38c Mon Sep 17 00:00:00 2001 From: Florian Charlier Date: Tue, 26 Mar 2024 15:42:12 +0100 Subject: [PATCH] [FIX] onboarding: skip test deleting a company In 8e3283aa we solved the issue of onboarding progress records preventing the deletion of a company. We also added a test for this solution. In practice, it will not always make sense nor will it be allowed to delete a company and in some cases, the first thing that would fail is a foreign key from another model where it wouldn't make sense to cascade as we do for onboarding progress. Some modules create related records when a company is created such that it would be cumbersome to bypass that. Therefore, we disable this test until a clean flow robust to all sorts of installed modules configuration is implemented. See runbot 60475 Task-3829936 closes odoo/odoo#159679 X-original-commit: ea215fe59b45a0c4ff29b4defb38f9ae91a6ca37 Signed-off-by: Thibault Delavallee (tde) --- addons/onboarding/tests/test_onboarding.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/addons/onboarding/tests/test_onboarding.py b/addons/onboarding/tests/test_onboarding.py index 40bf8055e72..32649804ad8 100644 --- a/addons/onboarding/tests/test_onboarding.py +++ b/addons/onboarding/tests/test_onboarding.py @@ -1,6 +1,8 @@ # -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. +import unittest + from psycopg2 import IntegrityError from odoo import Command @@ -217,6 +219,7 @@ class TestOnboarding(TestOnboardingCommon): self.step_initially_w_o_onboarding.with_company(self.company_2).action_set_just_done() self.assert_onboarding_is_done(self.onboarding_3.with_company(self.company_2)) + @unittest.skip("Company deletion can fail because of other foreign key constraints.") def test_remove_company_with_progress(self): user = mail_new_test_user( self.env,