From 68a5f5db7c970d22dc40637d7951b627fa50d5c1 Mon Sep 17 00:00:00 2001 From: Igor Kudrin Date: Thu, 10 Oct 2024 08:11:05 +0700 Subject: [lldb] Fix TestGlobalModuleCache.py for remote debugging (#111483) `SBDebugger().Create()` returns a debugger with only the host platform in its platform list. If the test suite is running for a remote platform, it should be explicitly added and selected in the new debugger created within the test, otherwise, the test will fail because the host platform may not be able to launch the built binary. --- lldb/test/API/python_api/global_module_cache/TestGlobalModuleCache.py | 1 + 1 file changed, 1 insertion(+) (limited to 'lldb/test/API/python_api') diff --git a/lldb/test/API/python_api/global_module_cache/TestGlobalModuleCache.py b/lldb/test/API/python_api/global_module_cache/TestGlobalModuleCache.py index ccefc28..5dd268b 100644 --- a/lldb/test/API/python_api/global_module_cache/TestGlobalModuleCache.py +++ b/lldb/test/API/python_api/global_module_cache/TestGlobalModuleCache.py @@ -111,6 +111,7 @@ class GlobalModuleCacheTestCase(TestBase): else: if one_target: new_debugger = lldb.SBDebugger().Create() + new_debugger.SetSelectedPlatform(lldb.selected_platform) new_debugger.SetAsync(False) self.old_debugger = self.dbg self.dbg = new_debugger -- cgit v1.1