fix: supervise management calls across cancellation and parent loss

This commit is contained in:
阿白叔 committed 2026-11-06 15:42:36 +08:00
1 parent 8d3eab1164
commit 6278091f21
8 files changed
+297 -24

No files matched your search

+2 -1
View File
@@ -99,7 +99,8 @@ def test_probe_preloads_uia_before_com_proxy_creation_but_catalog_stays_read_onl
monkeypatch.setattr(native, '_probe_add_dialog', editor)
monkeypatch.setattr(native, '_wait_native_exit', lambda pids: True)
result = native._catalog_native({'operation': operation, 'desktop': 'CbbManagement_test',
'library': str(library_path), 'mentor_home': str(tmp_path), 'probe_token': 'fixture'}, root)
'library': str(library_path), 'mentor_home': str(tmp_path), 'probe_token': 'fixture',
'supervisor_pid': __import__('os').getpid()}, root)
assert events[:2] == (['dispatch', 'library-close'] if operation == 'catalog' else ['uia-loaded', 'dispatch'])
if operation == 'catalog':
assert result['success'] and 'uia-loaded' not in events