Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,15 @@

class TestCase(TestBase):

@swiftTest
def test_backtrace_task_variable(self):
self.build()
lldbutil.run_to_source_breakpoint(
self, "break here", lldb.SBFileSpec("main.swift")
)
self.do_backtrace("task")

@swiftTest
def test_backtrace_task_address(self):
self.build()
_, _, thread, _ = lldbutil.run_to_source_breakpoint(
Expand Down
4 changes: 4 additions & 0 deletions lldb/test/API/lang/swift/async/tasks/TestSwiftTaskSelect.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,15 @@

class TestCase(TestBase):

@swiftTest
def test_backtrace_selected_task_variable(self):
self.build()
lldbutil.run_to_source_breakpoint(
self, "break here", lldb.SBFileSpec("main.swift")
)
self.do_backtrace_selected_task("task")

@swiftTest
def test_backtrace_selected_task_address(self):
self.build()
_, _, thread, _ = lldbutil.run_to_source_breakpoint(
Expand All @@ -35,13 +37,15 @@ def do_backtrace_selected_task(self, arg):
],
)

@swiftTest
def test_navigate_stack_of_selected_task_variable(self):
self.build()
_, process, thread, _ = lldbutil.run_to_source_breakpoint(
self, "break here", lldb.SBFileSpec("main.swift")
)
self.do_test_navigate_selected_task_stack(process, "task")

@swiftTest
def test_navigate_stack_of_selected_task_address(self):
self.build()
_, process, thread, _ = lldbutil.run_to_source_breakpoint(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@

import re


def _tail(output):
"""Delete the first line of output text."""
result, _ = re.subn(r"^.*\n", "", output, count=1)
Expand All @@ -15,6 +14,7 @@ def _tail(output):
class TestCase(TestBase):

@skipUnlessDarwin
@swiftTest
def test_compare_printed_task_variable_to_task_info(self):
"""Compare the output of a printed Task to the output of `task info`."""
self.build()
Expand All @@ -28,6 +28,7 @@ def test_compare_printed_task_variable_to_task_info(self):
self.assertEqual(_tail(task_info_output), _tail(frame_variable_output))

@skipUnlessDarwin
@swiftTest
def test_compare_printed_task_variable_to_task_info_with_address(self):
"""Compare the output of a printed Task to the output of `task info <address>`."""
self.build()
Expand Down