Author: Adrian Prantl
Date: 2025-10-24T11:29:11-07:00
New Revision: 4e7a8456b316bb20874cc1343747b36869eab7a2

URL: 
https://github.com/llvm/llvm-project/commit/4e7a8456b316bb20874cc1343747b36869eab7a2
DIFF: 
https://github.com/llvm/llvm-project/commit/4e7a8456b316bb20874cc1343747b36869eab7a2.diff

LOG: [lldb] Improve error logging in test (NFC)

Added: 
    

Modified: 
    lldb/test/API/macosx/posix_spawn/TestLaunchProcessPosixSpawn.py

Removed: 
    


################################################################################
diff  --git a/lldb/test/API/macosx/posix_spawn/TestLaunchProcessPosixSpawn.py 
b/lldb/test/API/macosx/posix_spawn/TestLaunchProcessPosixSpawn.py
index ffb6ef0fe4a18..8a321b2ff6324 100644
--- a/lldb/test/API/macosx/posix_spawn/TestLaunchProcessPosixSpawn.py
+++ b/lldb/test/API/macosx/posix_spawn/TestLaunchProcessPosixSpawn.py
@@ -36,9 +36,11 @@ def no_apple_silicon(self):
 
     def run_arch(self, exe, arch):
         self.runCmd("target create -arch {} {}".format(arch, exe))
-        self.runCmd("run")
-
-        process = self.dbg.GetSelectedTarget().process
+        target = self.dbg.GetSelectedTarget()
+        launch_info = target.GetLaunchInfo()
+        error = lldb.SBError()
+        process = target.Launch(launch_info, error)
+        self.assertTrue(error.Success, str(error))
         self.assertState(process.GetState(), lldb.eStateExited)
         self.assertIn("slice: {}".format(arch), process.GetSTDOUT(1000))
 


        
_______________________________________________
lldb-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to