llvm-project/lldb/test/API/macosx/debugserver-exit-code/TestDebugServerExitCode.py
Jason Molenda 8b65411b00
[lldb][NFC] Remove old skipIfOutOfTreeDebugserver's (#126144)
When a test depends on a new debugserver feature/fix, the API test must
be marked @skipIfOutOfTreeDebugserver because the macOS CI bots test
using the latest Xcode release debugserver. But over time all of these
fixes & new features are picked up in the Xcode debugserver and these
skips can be removed.

We may see unexpected test failures from removing all of these 1+ year
old skips, but that's likely a separate reason the test is failing that
is being papered over by this skip.
2025-02-06 14:50:09 -08:00

24 lines
745 B
Python

"""
Tests the exit code/description coming from the debugserver.
"""
import lldb
from lldbsuite.test.decorators import *
from lldbsuite.test.lldbtest import *
from lldbsuite.test import lldbutil
class TestCase(TestBase):
@no_debug_info_test
@skipUnlessDarwin
def test_abort(self):
self.build()
target = self.dbg.CreateTarget(self.getBuildArtifact("a.out"))
process = target.LaunchSimple(None, None, None)
# Continue until process is terminated.
process.Continue()
# Test for the abort signal code.
self.assertEqual(process.GetExitStatus(), 6)
# Test for the exit code description.
self.assertEqual(process.GetExitDescription(), "Terminated due to signal 6")