1
0
mirror of https://github.com/bec-project/bec_widgets.git synced 2026-04-29 19:42:29 +02:00

fix(dock-area): avoid switching profile when saving new profile

This commit is contained in:
2026-04-15 10:51:46 +02:00
parent a614d662d6
commit 653cbd5e3e
3 changed files with 16 additions and 7 deletions
+6 -1
View File
@@ -1863,9 +1863,14 @@ class TestWorkspaceProfileOperations:
with patch(
"bec_widgets.widgets.containers.dock_area.dock_area.SaveProfileDialog", StubDialog
):
advanced_dock_area.save_profile(show_dialog=True)
widgets_before_save = list(advanced_dock_area.widget_list())
with patch.object(advanced_dock_area, "load_profile") as mock_load_profile:
advanced_dock_area.save_profile(show_dialog=True)
qtbot.wait(100)
mock_load_profile.assert_not_called()
qtbot.wait(500)
assert list(advanced_dock_area.widget_list()) == widgets_before_save
source_manifest = read_manifest(helper.open_user(source_profile))
new_manifest = read_manifest(helper.open_user(new_profile))