diff options
author | Adrian Prantl <aprantl@apple.com> | 2018-01-19 23:24:35 +0000 |
---|---|---|
committer | Adrian Prantl <aprantl@apple.com> | 2018-01-19 23:24:35 +0000 |
commit | 595048f3ecf3317aa2d32bed5141a526415f5aea (patch) | |
tree | 92980c57a7209f1ec112bb5f938b2021fec08f21 /lldb/packages/Python/lldbsuite/test/functionalities/breakpoint | |
parent | ce8746d178dba08ae576c7f53448772d6728d2f5 (diff) | |
download | bcm5719-llvm-595048f3ecf3317aa2d32bed5141a526415f5aea.tar.gz bcm5719-llvm-595048f3ecf3317aa2d32bed5141a526415f5aea.zip |
Wrap all references to build artifacts in the LLDB testsuite (NFC)
in TestBase::getBuildArtifact(). This NFC commit is in preparation for
https://reviews.llvm.org/D42281 (compile the LLDB tests out-of-tree).
Differential Revision: https://reviews.llvm.org/D42280
llvm-svn: 323007
Diffstat (limited to 'lldb/packages/Python/lldbsuite/test/functionalities/breakpoint')
28 files changed, 38 insertions, 42 deletions
diff --git a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/address_breakpoints/TestAddressBreakpoints.py b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/address_breakpoints/TestAddressBreakpoints.py index 9b116a0a0a2..46191d85296 100644 --- a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/address_breakpoints/TestAddressBreakpoints.py +++ b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/address_breakpoints/TestAddressBreakpoints.py @@ -30,7 +30,7 @@ class AddressBreakpointTestCase(TestBase): def address_breakpoints(self): """Test address breakpoints set with shared library of SBAddress work correctly.""" - exe = os.path.join(os.getcwd(), "a.out") + exe = self.getBuildArtifact("a.out") # Create a target by the debugger. target = self.dbg.CreateTarget(exe) diff --git a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/auto_continue/TestBreakpointAutoContinue.py b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/auto_continue/TestBreakpointAutoContinue.py index 9630e39e014..0123e732e35 100644 --- a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/auto_continue/TestBreakpointAutoContinue.py +++ b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/auto_continue/TestBreakpointAutoContinue.py @@ -36,7 +36,7 @@ class BreakpointAutoContinue(TestBase): def make_target_and_bkpt(self, additional_options=None, num_expected_loc=1, pattern="Set a breakpoint here"): - exe = os.path.join(os.getcwd(), "a.out") + exe = self.getBuildArtifact("a.out") self.target = self.dbg.CreateTarget(exe) self.assertTrue(self.target.IsValid(), "Target is not valid") diff --git a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_case_sensitivity/TestBreakpointCaseSensitivity.py b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_case_sensitivity/TestBreakpointCaseSensitivity.py index 88ccc464419..97611a27dba 100644 --- a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_case_sensitivity/TestBreakpointCaseSensitivity.py +++ b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_case_sensitivity/TestBreakpointCaseSensitivity.py @@ -39,7 +39,7 @@ class BreakpointCaseSensitivityTestCase(TestBase): if case_insensitive: exe = exe.upper() - exe = os.path.join(os.getcwd(), exe) + exe = self.getBuildArtifact(exe) # Create a target by the debugger. self.target = self.dbg.CreateTarget(exe) diff --git a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_command/TestBreakpointCommand.py b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_command/TestBreakpointCommand.py index 386eafbb0b6..3b295486a23 100644 --- a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_command/TestBreakpointCommand.py +++ b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_command/TestBreakpointCommand.py @@ -51,7 +51,7 @@ class BreakpointCommandTestCase(TestBase): def breakpoint_command_sequence(self): """Test a sequence of breakpoint command add, list, and delete.""" - exe = os.path.join(os.getcwd(), "a.out") + exe = self.getBuildArtifact("a.out") self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Add three breakpoints on the same line. The first time we don't specify the file, @@ -237,7 +237,7 @@ class BreakpointCommandTestCase(TestBase): def breakpoint_command_script_parameters(self): """Test that the frame and breakpoint location are being properly passed to the script breakpoint command function.""" - exe = os.path.join(os.getcwd(), "a.out") + exe = self.getBuildArtifact("a.out") self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Add a breakpoint. @@ -280,7 +280,7 @@ class BreakpointCommandTestCase(TestBase): def breakpoint_commands_on_creation(self): """Test that setting breakpoint commands when creating the breakpoint works""" - exe = os.path.join(os.getcwd(), "a.out") + exe = self.getBuildArtifact("a.out") target = self.dbg.CreateTarget(exe) self.assertTrue(target.IsValid(), "Created an invalid target.") diff --git a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_command/TestBreakpointCommandsFromPython.py b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_command/TestBreakpointCommandsFromPython.py index 01af8369aaf..1fc3269d3d5 100644 --- a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_command/TestBreakpointCommandsFromPython.py +++ b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_command/TestBreakpointCommandsFromPython.py @@ -31,7 +31,7 @@ class PythonBreakpointCommandSettingTestCase(TestBase): self.main_source_spec = lldb.SBFileSpec(self.main_source) def do_set_python_command_from_python(self): - exe = os.path.join(os.getcwd(), "a.out") + exe = self.getBuildArtifact("a.out") error = lldb.SBError() self.target = self.dbg.CreateTarget(exe) diff --git a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_command/TestRegexpBreakCommand.py b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_command/TestRegexpBreakCommand.py index baf237bf076..059c9232e4c 100644 --- a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_command/TestRegexpBreakCommand.py +++ b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_command/TestRegexpBreakCommand.py @@ -31,7 +31,7 @@ class RegexpBreakCommandTestCase(TestBase): def regexp_break_command(self): """Test the super consie "b" command, which is analias for _regexp-break.""" - exe = os.path.join(os.getcwd(), "a.out") + exe = self.getBuildArtifact("a.out") self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) break_results = lldbutil.run_break_set_command( diff --git a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_conditions/TestBreakpointConditions.py b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_conditions/TestBreakpointConditions.py index 3fd9b13c711..959c7e8f95c 100644 --- a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_conditions/TestBreakpointConditions.py +++ b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_conditions/TestBreakpointConditions.py @@ -59,7 +59,7 @@ class BreakpointConditionsTestCase(TestBase): def breakpoint_conditions(self, inline=False): """Exercise breakpoint condition with 'breakpoint modify -c <expr> id'.""" - exe = os.path.join(os.getcwd(), "a.out") + exe = self.getBuildArtifact("a.out") self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) if inline: @@ -132,7 +132,7 @@ class BreakpointConditionsTestCase(TestBase): def breakpoint_conditions_python(self): """Use Python APIs to set breakpoint conditions.""" - exe = os.path.join(os.getcwd(), "a.out") + exe = self.getBuildArtifact("a.out") # Create a target by the debugger. target = self.dbg.CreateTarget(exe) @@ -200,7 +200,7 @@ class BreakpointConditionsTestCase(TestBase): def breakpoint_invalid_conditions_python(self): """Use Python APIs to set breakpoint conditions.""" - exe = os.path.join(os.getcwd(), "a.out") + exe = self.getBuildArtifact("a.out") # Create a target by the debugger. target = self.dbg.CreateTarget(exe) diff --git a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_hit_count/TestBreakpointHitCount.py b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_hit_count/TestBreakpointHitCount.py index 5d7b6f9169a..e1281e63761 100644 --- a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_hit_count/TestBreakpointHitCount.py +++ b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_hit_count/TestBreakpointHitCount.py @@ -32,7 +32,7 @@ class BreakpointHitCountTestCase(TestBase): def do_test_breakpoint_location_hit_count(self): """Use Python APIs to check breakpoint hit count.""" - exe = os.path.join(os.getcwd(), "a.out") + exe = self.getBuildArtifact("a.out") target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) diff --git a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_ids/TestBreakpointIDs.py b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_ids/TestBreakpointIDs.py index 621bd4a55f0..02fb1e0f49d 100644 --- a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_ids/TestBreakpointIDs.py +++ b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_ids/TestBreakpointIDs.py @@ -19,7 +19,7 @@ class BreakpointIDTestCase(TestBase): def test(self): self.build() - exe = os.path.join(os.getcwd(), "a.out") + exe = self.getBuildArtifact("a.out") self.expect("file " + exe, patterns=["Current executable set to .*a.out"]) diff --git a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_ignore_count/TestBreakpointIgnoreCount.py b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_ignore_count/TestBreakpointIgnoreCount.py index 09e20bc5ac3..eb4bac7e6e6 100644 --- a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_ignore_count/TestBreakpointIgnoreCount.py +++ b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_ignore_count/TestBreakpointIgnoreCount.py @@ -46,7 +46,7 @@ class BreakpointIgnoreCountTestCase(TestBase): def breakpoint_ignore_count(self): """Exercise breakpoint ignore count with 'breakpoint set -i <count>'.""" - exe = os.path.join(os.getcwd(), "a.out") + exe = self.getBuildArtifact("a.out") self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Create a breakpoint in main.c at line1. @@ -101,7 +101,7 @@ class BreakpointIgnoreCountTestCase(TestBase): def breakpoint_ignore_count_python(self): """Use Python APIs to set breakpoint ignore count.""" - exe = os.path.join(os.getcwd(), "a.out") + exe = self.getBuildArtifact("a.out") # Create a target by the debugger. target = self.dbg.CreateTarget(exe) diff --git a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_in_delayslot/TestAvoidBreakpointInDelaySlot.py b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_in_delayslot/TestAvoidBreakpointInDelaySlot.py index 255b6f7fa29..6eaab0c680f 100644 --- a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_in_delayslot/TestAvoidBreakpointInDelaySlot.py +++ b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_in_delayslot/TestAvoidBreakpointInDelaySlot.py @@ -21,7 +21,7 @@ class AvoidBreakpointInDelaySlotAPITestCase(TestBase): @skipIf(archs=no_match(re.compile('mips*'))) def test(self): self.build() - exe = os.path.join(os.getcwd(), "a.out") + exe = self.getBuildArtifact("a.out") self.expect("file " + exe, patterns=["Current executable set to .*a.out.*"]) diff --git a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_language/TestBreakpointLanguage.py b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_language/TestBreakpointLanguage.py index 214c110afcd..b69007014b1 100644 --- a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_language/TestBreakpointLanguage.py +++ b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_language/TestBreakpointLanguage.py @@ -36,7 +36,7 @@ class TestBreakpointLanguage(TestBase): self.build() # Create a target by the debugger. - exe = os.path.join(os.getcwd(), "a.out") + exe = self.getBuildArtifact("a.out") error = lldb.SBError() # Don't read in dependencies so we don't come across false matches that # add unwanted breakpoint hits. @@ -77,7 +77,7 @@ class TestBreakpointLanguage(TestBase): self.build() # Create a target by the debugger. - exe = os.path.join(os.getcwd(), "a.out") + exe = self.getBuildArtifact("a.out") error = lldb.SBError() # Don't read in dependencies so we don't come across false matches that # add unwanted breakpoint hits. diff --git a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_locations/TestBreakpointLocations.py b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_locations/TestBreakpointLocations.py index de24d8b002d..7eb465f2959 100644 --- a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_locations/TestBreakpointLocations.py +++ b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_locations/TestBreakpointLocations.py @@ -41,7 +41,7 @@ class BreakpointLocationsTestCase(TestBase): self.line = line_number('main.c', '// Set break point at this line.') def set_breakpoint (self): - exe = os.path.join(os.getcwd(), "a.out") + exe = self.getBuildArtifact("a.out") target = self.dbg.CreateTarget(exe) self.assertTrue(target, "Target %s is not valid"%(exe)) diff --git a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_names/TestBreakpointNames.py b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_names/TestBreakpointNames.py index b95d2cea550..8130679c0f6 100644 --- a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_names/TestBreakpointNames.py +++ b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_names/TestBreakpointNames.py @@ -58,7 +58,7 @@ class BreakpointNames(TestBase): self.do_check_configuring_permissions_cli() def setup_target(self): - exe = os.path.join(os.getcwd(), "a.out") + exe = self.getBuildArtifact("a.out") # Create a targets we are making breakpoint in and copying to: self.target = self.dbg.CreateTarget(exe) diff --git a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_options/TestBreakpointOptions.py b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_options/TestBreakpointOptions.py index 871363b7aed..c9ef2a73001 100644 --- a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_options/TestBreakpointOptions.py +++ b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_options/TestBreakpointOptions.py @@ -28,7 +28,7 @@ class BreakpointOptionsTestCase(TestBase): def breakpoint_options_test(self): """Test breakpoint command for different options.""" - exe = os.path.join(os.getcwd(), "a.out") + exe = self.getBuildArtifact("a.out") self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # This should create a breakpoint with 1 locations. @@ -78,7 +78,7 @@ class BreakpointOptionsTestCase(TestBase): def breakpoint_options_language_test(self): """Test breakpoint command for language option.""" - exe = os.path.join(os.getcwd(), "a.out") + exe = self.getBuildArtifact("a.out") self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # This should create a breakpoint with 1 locations. diff --git a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_set_restart/TestBreakpointSetRestart.py b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_set_restart/TestBreakpointSetRestart.py index 2410f2ee82b..958a17d83c9 100644 --- a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_set_restart/TestBreakpointSetRestart.py +++ b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/breakpoint_set_restart/TestBreakpointSetRestart.py @@ -16,7 +16,7 @@ class BreakpointSetRestart(TestBase): self.build() cwd = os.getcwd() - exe = os.path.join(cwd, 'a.out') + exe = self.getBuildArtifact("a.out") target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) diff --git a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/cpp/TestCPPBreakpointLocations.py b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/cpp/TestCPPBreakpointLocations.py index adec9fa5ddd..e4c19fd0d3d 100644 --- a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/cpp/TestCPPBreakpointLocations.py +++ b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/cpp/TestCPPBreakpointLocations.py @@ -45,7 +45,7 @@ class TestCPPBreakpointLocations(TestBase): def breakpoint_id_tests(self): # Create a target by the debugger. - exe = os.path.join(os.getcwd(), "a.out") + exe = self.getBuildArtifact("a.out") target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) bp_dicts = [ @@ -69,7 +69,7 @@ class TestCPPBreakpointLocations(TestBase): @expectedFailureAll(oslist=["windows"], bugnumber="llvm.org/pr24764") def test_destructors(self): self.build() - exe = os.path.join(os.getcwd(), "a.out") + exe = self.getBuildArtifact("a.out") target = self.dbg.CreateTarget(exe) # Don't skip prologue, so we can check the breakpoint address more diff --git a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/cpp_exception/TestCPPExceptionBreakpoint.py b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/cpp_exception/TestCPPExceptionBreakpoint.py index 3019e1c1c55..26fe02ba56c 100644 --- a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/cpp_exception/TestCPPExceptionBreakpoint.py +++ b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/cpp_exception/TestCPPExceptionBreakpoint.py @@ -32,7 +32,7 @@ class TestCPPExceptionBreakpoint (TestBase): self.main_source_spec = lldb.SBFileSpec(self.main_source) def do_cpp_exception_bkpt(self): - exe = os.path.join(os.getcwd(), "a.out") + exe = self.getBuildArtifact("a.out") error = lldb.SBError() self.target = self.dbg.CreateTarget(exe) diff --git a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/debugbreak/TestDebugBreak.py b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/debugbreak/TestDebugBreak.py index d044827e008..11ec67d9109 100644 --- a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/debugbreak/TestDebugBreak.py +++ b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/debugbreak/TestDebugBreak.py @@ -20,7 +20,7 @@ class DebugBreakTestCase(TestBase): def test_asm_int_3(self): """Test that intrinsics like `__debugbreak();` and `asm {"int3"}` are treated like breakpoints.""" self.build() - exe = os.path.join(os.getcwd(), "a.out") + exe = self.getBuildArtifact("a.out") # Run the program. target = self.dbg.CreateTarget(exe) diff --git a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/dummy_target_breakpoints/TestBreakpointsWithNoTargets.py b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/dummy_target_breakpoints/TestBreakpointsWithNoTargets.py index a934ad356ac..4b595ab7819 100644 --- a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/dummy_target_breakpoints/TestBreakpointsWithNoTargets.py +++ b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/dummy_target_breakpoints/TestBreakpointsWithNoTargets.py @@ -46,7 +46,7 @@ class BreakpointInDummyTarget (TestBase): # Execute the cleanup function during test case tear down. self.addTearDownHook(cleanup) - exe = os.path.join(os.getcwd(), "a.out") + exe = self.getBuildArtifact("a.out") self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # The breakpoint list should show 3 locations. diff --git a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/global_constructor/TestBreakpointInGlobalConstructor.py b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/global_constructor/TestBreakpointInGlobalConstructor.py index 236912b1f18..5f0e7a058a4 100644 --- a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/global_constructor/TestBreakpointInGlobalConstructor.py +++ b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/global_constructor/TestBreakpointInGlobalConstructor.py @@ -22,7 +22,7 @@ class TestBreakpointInGlobalConstructors(TestBase): self.line_foo = line_number('foo.cpp', '// !BR_foo') self.line_main = line_number('main.cpp', '// !BR_main') - target = self.dbg.CreateTarget("a.out") + target = self.dbg.CreateTarget(self.getBuildArtifact("a.out")) self.assertTrue(target, VALID_TARGET) env= self.registerSharedLibrariesWithTarget(target, ["foo"]) diff --git a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/hardware_breakpoints/hardware_breakpoint_on_multiple_threads/TestHWBreakMultiThread.py b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/hardware_breakpoints/hardware_breakpoint_on_multiple_threads/TestHWBreakMultiThread.py index 21fe084d3df..69dfac22525 100644 --- a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/hardware_breakpoints/hardware_breakpoint_on_multiple_threads/TestHWBreakMultiThread.py +++ b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/hardware_breakpoints/hardware_breakpoint_on_multiple_threads/TestHWBreakMultiThread.py @@ -47,12 +47,8 @@ class HardwareBreakpointMultiThreadTestCase(TestBase): def break_multi_thread(self, removal_type): """Test that lldb hardware breakpoints work for multiple threads.""" - self.runCmd( - "file %s" % - os.path.join( - os.getcwd(), - 'a.out'), - CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getBuildArtifact("a.out"), + CURRENT_EXECUTABLE_SET) # Stop in main before creating any threads. lldbutil.run_break_set_by_file_and_line( diff --git a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/inlined_breakpoints/TestInlinedBreakpoints.py b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/inlined_breakpoints/TestInlinedBreakpoints.py index fe8f430096d..ee67dda6242 100644 --- a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/inlined_breakpoints/TestInlinedBreakpoints.py +++ b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/inlined_breakpoints/TestInlinedBreakpoints.py @@ -33,7 +33,7 @@ class InlinedBreakpointsTestCase(TestBase): def inlined_breakpoints(self): """Test 'b basic_types.cpp:176' does break (where int.cpp includes basic_type.cpp).""" - exe = os.path.join(os.getcwd(), "a.out") + exe = self.getBuildArtifact("a.out") self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # With the inline-breakpoint-strategy, our file+line breakpoint should diff --git a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/move_nearest/TestMoveNearest.py b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/move_nearest/TestMoveNearest.py index 26041c313e5..16d5bc75473 100644 --- a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/move_nearest/TestMoveNearest.py +++ b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/move_nearest/TestMoveNearest.py @@ -24,7 +24,7 @@ class TestMoveNearest(TestBase): """Test target.move-to-nearest logic""" self.build() - target = self.dbg.CreateTarget("a.out") + target = self.dbg.CreateTarget(self.getBuildArtifact("a.out")) self.assertTrue(target, VALID_TARGET) lldbutil.run_break_set_by_symbol(self, 'main', sym_exact=True) diff --git a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/objc/TestObjCBreakpoints.py b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/objc/TestObjCBreakpoints.py index f43bbb7515c..799206719b1 100644 --- a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/objc/TestObjCBreakpoints.py +++ b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/objc/TestObjCBreakpoints.py @@ -73,7 +73,7 @@ class TestObjCBreakpoints(TestBase): self.dbg.SetAsync(False) # Create a target by the debugger. - exe = os.path.join(os.getcwd(), "a.out") + exe = self.getBuildArtifact("a.out") self.target = self.dbg.CreateTarget(exe) self.assertTrue(self.target, VALID_TARGET) diff --git a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/serialize/TestBreakpointSerialization.py b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/serialize/TestBreakpointSerialization.py index 6f93994a466..34ce8868b8f 100644 --- a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/serialize/TestBreakpointSerialization.py +++ b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/serialize/TestBreakpointSerialization.py @@ -60,7 +60,7 @@ class BreakpointSerialization(TestBase): self.addTearDownHook(cleanup) self.RemoveTempFile(self.bkpts_file_path) - exe = os.path.join(os.getcwd(), "a.out") + exe = self.getBuildArtifact("a.out") # Create the targets we are making breakpoints in and copying them to: self.orig_target = self.dbg.CreateTarget(exe) diff --git a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/source_regexp/TestSourceRegexBreakpoints.py b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/source_regexp/TestSourceRegexBreakpoints.py index 791cc70a749..4256c70a026 100644 --- a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/source_regexp/TestSourceRegexBreakpoints.py +++ b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/source_regexp/TestSourceRegexBreakpoints.py @@ -28,7 +28,7 @@ class TestSourceRegexBreakpoints(TestBase): def source_regex_locations(self): """ Test that restricting source expressions to files & to functions. """ # Create a target by the debugger. - exe = os.path.join(os.getcwd(), "a.out") + exe = self.getBuildArtifact("a.out") target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) @@ -64,7 +64,7 @@ class TestSourceRegexBreakpoints(TestBase): def source_regex_restrictions(self): """ Test that restricting source expressions to files & to functions. """ # Create a target by the debugger. - exe = os.path.join(os.getcwd(), "a.out") + exe = self.getBuildArtifact("a.out") target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) diff --git a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/step_over_breakpoint/TestStepOverBreakpoint.py b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/step_over_breakpoint/TestStepOverBreakpoint.py index 4dfeae3f5e1..c2084295ef7 100644 --- a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/step_over_breakpoint/TestStepOverBreakpoint.py +++ b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/step_over_breakpoint/TestStepOverBreakpoint.py @@ -21,7 +21,7 @@ class StepOverBreakpointsTestCase(TestBase): TestBase.setUp(self) self.build() - exe = os.path.join(os.getcwd(), "a.out") + exe = self.getBuildArtifact("a.out") src = lldb.SBFileSpec("main.cpp") # Create a target by the debugger. |