Index: lldb/packages/Python/lldbsuite/test/builders/builder.py =================================================================== --- lldb/packages/Python/lldbsuite/test/builders/builder.py +++ lldb/packages/Python/lldbsuite/test/builders/builder.py @@ -120,6 +120,11 @@ configuration.clang_module_cache_dir)] return [] + def getExecutable(self, test_exe): + if test_exe: + return ["EXE_NAME={}".format(test_exe)] + return [] + def _getDebugInfoArgs(self, debug_info): if debug_info is None: return [] @@ -132,7 +137,7 @@ return None def getBuildCommand(self, debug_info, architecture=None, compiler=None, - dictionary=None, testdir=None, testname=None): + dictionary=None, testdir=None, testname=None, testexe=None): debug_info_args = self._getDebugInfoArgs(debug_info) if debug_info_args is None: return None @@ -142,7 +147,7 @@ self.getArchCFlags(architecture), self.getArchSpec(architecture), self.getCCSpec(compiler), self.getExtraMakeArgs(), self.getSDKRootSpec(), self.getModuleCacheSpec(), - self.getCmdLine(dictionary)] + self.getExecutable(testexe), self.getCmdLine(dictionary)] command = list(itertools.chain(*command_parts)) return command Index: lldb/packages/Python/lldbsuite/test/lldbtest.py =================================================================== --- lldb/packages/Python/lldbsuite/test/lldbtest.py +++ lldb/packages/Python/lldbsuite/test/lldbtest.py @@ -701,7 +701,7 @@ shutil.rmtree(bdir) lldbutil.mkdir_p(bdir) - def getBuildArtifact(self): + def getBuildArtifact(self, name): """Return absolute path to an artifact in the test's build directory.""" return os.path.join(self.getBuildDir(), name) @@ -709,6 +709,13 @@ """Return absolute path to a file in the test's source directory.""" return os.path.join(self.getSourceDir(), name) + def getTestExecutableName(self): + return "a.out" + + def getTestExecutable(self): + """Return absolute path to the test executable.""" + return os.path.join(self.getBuildDir(), self.getTestExecutableName()) + @classmethod def setUpCommands(cls): commands = [ @@ -1420,10 +1427,11 @@ testdir = self.mydir testname = self.getBuildDirBasename() + testexe = self.getTestExecutableName() module = builder_module() command = builder_module().getBuildCommand(debug_info, architecture, - compiler, dictionary, testdir, testname) + compiler, dictionary, testdir, testname, testexe) if command is None: raise Exception("Don't know how to build binary") Index: lldb/packages/Python/lldbsuite/test/lldbutil.py =================================================================== --- lldb/packages/Python/lldbsuite/test/lldbutil.py +++ lldb/packages/Python/lldbsuite/test/lldbutil.py @@ -741,8 +741,8 @@ expected_location_hit_count = None): """ Test breakpoint or breakpoint location. - Breakpoint resolved count is always checked. If not specified the assumption is that all locations - should be resolved. + Breakpoint resolved count is always checked. If not specified the assumption is that all locations + should be resolved. To test a breakpoint location, breakpoint number (bpno) and location_id must be set. In this case the resolved count for a breakpoint is not tested by default. The location is expected to be resolved, unless expected_location_resolved is set to False. @@ -898,9 +898,11 @@ # Helper functions for run_to_{source,name}_breakpoint: -def run_to_breakpoint_make_target(test, exe_name = "a.out", in_cwd = True): - if in_cwd: +def run_to_breakpoint_make_target(test, exe_name = None, in_cwd=True): + if exe_name: exe = test.getBuildArtifact(exe_name) + else: + exe = test.getTestExecutable() # Create the target target = test.dbg.CreateTarget(exe) @@ -961,7 +963,7 @@ return (target, process, thread, bkpt) def run_to_name_breakpoint (test, bkpt_name, launch_info = None, - exe_name = "a.out", + exe_name = None, bkpt_module = None, in_cwd = True, only_one_thread = True, @@ -1029,7 +1031,7 @@ only_one_thread, extra_images) def run_to_line_breakpoint(test, source_spec, line_number, column = 0, - launch_info = None, exe_name = "a.out", + launch_info = None, exe_name = None, bkpt_module = None, in_cwd = True, only_one_thread = True, @@ -1558,10 +1560,10 @@ command += " -s {0}".format(stop_action) if notify_action != None: command +=" -n {0}".format(notify_action) - + testcase.dbg.GetCommandInterpreter().HandleCommand(command, return_obj) testcase.assertEqual(expect_success, - return_obj.Succeeded(), + return_obj.Succeeded(), "Setting signal handling for {0} worked as expected".format(signal_name)) class PrintableRegex(object): Index: lldb/packages/Python/lldbsuite/test/make/Makefile.rules =================================================================== --- lldb/packages/Python/lldbsuite/test/make/Makefile.rules +++ lldb/packages/Python/lldbsuite/test/make/Makefile.rules @@ -285,7 +285,8 @@ endif endif OBJECTS = -EXE ?= a.out +EXE_NAME ?= a.out +EXE ?= $(EXE_NAME) ifneq "$(FRAMEWORK)" "" DYLIB_NAME ?= $(FRAMEWORK).framework/Versions/A/$(FRAMEWORK) Index: lldb/test/API/api/check_public_api_headers/TestPublicAPIHeaders.py =================================================================== --- lldb/test/API/api/check_public_api_headers/TestPublicAPIHeaders.py +++ lldb/test/API/api/check_public_api_headers/TestPublicAPIHeaders.py @@ -32,13 +32,13 @@ self.skipTest( "LLDB is 64-bit and cannot be linked to 32-bit test program.") - exe_name = self.getBuildArtifact("a.out") + exe_name = self.getTestExecutable() self.buildDriver(self.source, exe_name) self.sanity_check_executable(exe_name) def sanity_check_executable(self, exe_name): """Sanity check executable compiled from the auto-generated program.""" - exe_name = self.getBuildArtifact("a.out") + exe_name = self.getTestExecutable() exe = self.getBuildArtifact(exe_name) self.runCmd("file %s" % exe, CURRENT_EXECUTABLE_SET) Index: lldb/test/API/arm/breakpoint-it/TestBreakpointIt.py =================================================================== --- lldb/test/API/arm/breakpoint-it/TestBreakpointIt.py +++ lldb/test/API/arm/breakpoint-it/TestBreakpointIt.py @@ -19,7 +19,7 @@ @skipIf(archs=["arm64", "arm64e", "arm64_32"]) def test_false(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("target create %s" % exe) lldbutil.run_break_set_by_symbol(self, "bkpt_false", @@ -33,7 +33,7 @@ @skipIf(archs=["arm64", "arm64e", "arm64_32"]) def test_true(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("target create %s" % exe) bpid = lldbutil.run_break_set_by_symbol(self, "bkpt_true", Index: lldb/test/API/arm/breakpoint-thumb-codesection/TestBreakpointThumbCodesection.py =================================================================== --- lldb/test/API/arm/breakpoint-thumb-codesection/TestBreakpointThumbCodesection.py +++ lldb/test/API/arm/breakpoint-thumb-codesection/TestBreakpointThumbCodesection.py @@ -19,7 +19,7 @@ @skipIfDarwinEmbedded # codegen on darwin always defaults to thumb for armv7/armv7k targets def test_breakpoint(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() line = line_number('main.c', '// Set break point at this line.') self.runCmd("target create %s" % exe) Index: lldb/test/API/benchmarks/continue/TestBenchmarkContinue.py =================================================================== --- lldb/test/API/benchmarks/continue/TestBenchmarkContinue.py +++ lldb/test/API/benchmarks/continue/TestBenchmarkContinue.py @@ -28,7 +28,7 @@ def data_formatter_commands(self): """Benchmark different ways to continue a process""" - self.runCmd("file "+self.getBuildArtifact("a.out"), + self.runCmd("file "+self.getTestExecutable(), CURRENT_EXECUTABLE_SET) bkpt = self.target().FindBreakpointByID( Index: lldb/test/API/benchmarks/libcxxlist/TestBenchmarkLibcxxList.py =================================================================== --- lldb/test/API/benchmarks/libcxxlist/TestBenchmarkLibcxxList.py +++ lldb/test/API/benchmarks/libcxxlist/TestBenchmarkLibcxxList.py @@ -28,7 +28,7 @@ def data_formatter_commands(self): """Benchmark the std::list data formatter (libc++)""" - self.runCmd("file " + self.getBuildArtifact("a.out"), + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) bkpt = self.target().FindBreakpointByID( Index: lldb/test/API/benchmarks/libcxxmap/TestBenchmarkLibcxxMap.py =================================================================== --- lldb/test/API/benchmarks/libcxxmap/TestBenchmarkLibcxxMap.py +++ lldb/test/API/benchmarks/libcxxmap/TestBenchmarkLibcxxMap.py @@ -28,7 +28,7 @@ def data_formatter_commands(self): """Benchmark the std::map data formatter (libc++)""" - self.runCmd("file " +self.getBuildArtifact("a.out"), + self.runCmd("file " +self.getTestExecutable(), CURRENT_EXECUTABLE_SET) bkpt = self.target().FindBreakpointByID( Index: lldb/test/API/commands/apropos/with-process/TestAproposWithProcess.py =================================================================== --- lldb/test/API/commands/apropos/with-process/TestAproposWithProcess.py +++ lldb/test/API/commands/apropos/with-process/TestAproposWithProcess.py @@ -23,7 +23,7 @@ def test_apropos_with_process(self): """Test that apropos env doesn't crash trying to touch the process plugin command.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Break in main() after the variables are assigned values. Index: lldb/test/API/commands/command/nested_alias/TestNestedAlias.py =================================================================== --- lldb/test/API/commands/command/nested_alias/TestNestedAlias.py +++ lldb/test/API/commands/command/nested_alias/TestNestedAlias.py @@ -23,7 +23,7 @@ def test_nested_alias(self): """Test that an alias can reference other aliases without crashing.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Break in main() after the variables are assigned values. Index: lldb/test/API/commands/command/script/TestCommandScript.py =================================================================== --- lldb/test/API/commands/command/script/TestCommandScript.py +++ lldb/test/API/commands/command/script/TestCommandScript.py @@ -41,7 +41,7 @@ self.expect('targetname', substrs=['a.out'], matching=False, error=True) - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.expect("file " + exe, patterns=["Current executable set to .*a.out"]) Index: lldb/test/API/commands/expression/formatters/TestFormatters.py =================================================================== --- lldb/test/API/commands/expression/formatters/TestFormatters.py +++ lldb/test/API/commands/expression/formatters/TestFormatters.py @@ -37,7 +37,7 @@ self.addTearDownHook(cleanup) """Test expr + formatters for good interoperability.""" - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, loc_exact=True) Index: lldb/test/API/commands/expression/ir-interpreter-phi-nodes/TestIRInterpreterPHINodes.py =================================================================== --- lldb/test/API/commands/expression/ir-interpreter-phi-nodes/TestIRInterpreterPHINodes.py +++ lldb/test/API/commands/expression/ir-interpreter-phi-nodes/TestIRInterpreterPHINodes.py @@ -15,7 +15,7 @@ """Test support for PHI nodes in the IR interpreter.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd('file ' + exe, CURRENT_EXECUTABLE_SET) # Break on the first assignment to i Index: lldb/test/API/commands/expression/ir-interpreter/TestIRInterpreter.py =================================================================== --- lldb/test/API/commands/expression/ir-interpreter/TestIRInterpreter.py +++ lldb/test/API/commands/expression/ir-interpreter/TestIRInterpreter.py @@ -32,7 +32,7 @@ """Test the IR interpreter""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.c", self.line, num_expected_locations=1, loc_exact=False) Index: lldb/test/API/commands/expression/multiline-completion/TestMultilineCompletion.py =================================================================== --- lldb/test/API/commands/expression/multiline-completion/TestMultilineCompletion.py +++ lldb/test/API/commands/expression/multiline-completion/TestMultilineCompletion.py @@ -36,7 +36,7 @@ """Test that we can complete a simple multiline expression""" self.build() - self.launch(executable=self.getBuildArtifact("a.out"), dimensions=(100,500)) + self.launch(executable=self.getTestExecutable(), dimensions=(100,500)) self.expect("b main", substrs=["Breakpoint 1", "address ="]) self.expect("run", substrs=["stop reason = breakpoint 1"]) Index: lldb/test/API/commands/expression/options/TestExprOptions.py =================================================================== --- lldb/test/API/commands/expression/options/TestExprOptions.py +++ lldb/test/API/commands/expression/options/TestExprOptions.py @@ -26,7 +26,7 @@ self.main_source = "main.cpp" self.main_source_spec = lldb.SBFileSpec(self.main_source) self.line = line_number('main.cpp', '// breakpoint_in_main') - self.exe = self.getBuildArtifact("a.out") + self.exe = self.getTestExecutable() def test_expr_options(self): """These expression command options should work as expected.""" Index: lldb/test/API/commands/expression/persist_objc_pointeetype/TestPersistObjCPointeeType.py =================================================================== --- lldb/test/API/commands/expression/persist_objc_pointeetype/TestPersistObjCPointeeType.py +++ lldb/test/API/commands/expression/persist_objc_pointeetype/TestPersistObjCPointeeType.py @@ -33,7 +33,7 @@ # Execute the cleanup function during test case tear down. self.addTearDownHook(cleanup) - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.m", self.line, loc_exact=True) Index: lldb/test/API/commands/expression/persistent_ptr_update/TestPersistentPtrUpdate.py =================================================================== --- lldb/test/API/commands/expression/persistent_ptr_update/TestPersistentPtrUpdate.py +++ lldb/test/API/commands/expression/persistent_ptr_update/TestPersistentPtrUpdate.py @@ -23,7 +23,7 @@ # Execute the cleanup function during test case tear down. self.addTearDownHook(cleanup) - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) self.runCmd('break set -p here') Index: lldb/test/API/commands/expression/persistent_types/TestNestedPersistentTypes.py =================================================================== --- lldb/test/API/commands/expression/persistent_types/TestNestedPersistentTypes.py +++ lldb/test/API/commands/expression/persistent_types/TestNestedPersistentTypes.py @@ -18,7 +18,7 @@ """Test that nested persistent types work.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) self.runCmd("breakpoint set --name main") Index: lldb/test/API/commands/expression/persistent_types/TestPersistentTypes.py =================================================================== --- lldb/test/API/commands/expression/persistent_types/TestPersistentTypes.py +++ lldb/test/API/commands/expression/persistent_types/TestPersistentTypes.py @@ -18,7 +18,7 @@ """Test that lldb persistent types works correctly.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) self.runCmd("breakpoint set --name main") Index: lldb/test/API/commands/expression/po_verbosity/TestPoVerbosity.py =================================================================== --- lldb/test/API/commands/expression/po_verbosity/TestPoVerbosity.py +++ lldb/test/API/commands/expression/po_verbosity/TestPoVerbosity.py @@ -36,7 +36,7 @@ self.addTearDownHook(cleanup) """Test expr + formatters for good interoperability.""" - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.m", self.line, loc_exact=True) Index: lldb/test/API/commands/expression/radar_8638051/Test8638051.py =================================================================== --- lldb/test/API/commands/expression/radar_8638051/Test8638051.py +++ lldb/test/API/commands/expression/radar_8638051/Test8638051.py @@ -16,7 +16,7 @@ """The following expression commands should not crash.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) self.runCmd("breakpoint set -n c") Index: lldb/test/API/commands/expression/radar_9531204/TestPrintfAfterUp.py =================================================================== --- lldb/test/API/commands/expression/radar_9531204/TestPrintfAfterUp.py +++ lldb/test/API/commands/expression/radar_9531204/TestPrintfAfterUp.py @@ -19,7 +19,7 @@ """The evaluating printf(...) after break stop and then up a stack frame.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_symbol( self, 'foo', sym_exact=True, num_expected_locations=1) Index: lldb/test/API/commands/expression/radar_9673664/TestExprHelpExamples.py =================================================================== --- lldb/test/API/commands/expression/radar_9673664/TestExprHelpExamples.py +++ lldb/test/API/commands/expression/radar_9673664/TestExprHelpExamples.py @@ -25,7 +25,7 @@ """The following expression commands should just work.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, Index: lldb/test/API/commands/expression/test/TestExprs.py =================================================================== --- lldb/test/API/commands/expression/test/TestExprs.py +++ lldb/test/API/commands/expression/test/TestExprs.py @@ -42,7 +42,7 @@ """These basic expression commands should work as expected.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=False) @@ -177,7 +177,7 @@ """Throw some expression commands with quotes at lldb.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=False) Index: lldb/test/API/commands/expression/test/TestExprs2.py =================================================================== --- lldb/test/API/commands/expression/test/TestExprs2.py +++ lldb/test/API/commands/expression/test/TestExprs2.py @@ -26,7 +26,7 @@ """Test some more expression commands.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=False) @@ -60,7 +60,7 @@ """Test symbols.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=False) Index: lldb/test/API/commands/expression/top-level/TestTopLevelExprs.py =================================================================== --- lldb/test/API/commands/expression/top-level/TestTopLevelExprs.py +++ lldb/test/API/commands/expression/top-level/TestTopLevelExprs.py @@ -34,7 +34,7 @@ """Test top-level expressions.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=False) Index: lldb/test/API/commands/expression/two-files/TestObjCTypeQueryFromOtherCompileUnit.py =================================================================== --- lldb/test/API/commands/expression/two-files/TestObjCTypeQueryFromOtherCompileUnit.py +++ lldb/test/API/commands/expression/two-files/TestObjCTypeQueryFromOtherCompileUnit.py @@ -27,7 +27,7 @@ def test(self): """The expression parser's type search should be wider than the current compilation unit.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.m", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/commands/frame/diagnose/array/TestArray.py =================================================================== --- lldb/test/API/commands/frame/diagnose/array/TestArray.py +++ lldb/test/API/commands/frame/diagnose/array/TestArray.py @@ -16,7 +16,7 @@ @skipIf(archs=no_match(['x86_64'])) # frame diagnose doesn't work for armv7 or arm64 def test_array(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) self.runCmd("run", RUN_SUCCEEDED) self.expect("thread list", "Thread should be stopped", Index: lldb/test/API/commands/frame/diagnose/bad-reference/TestBadReference.py =================================================================== --- lldb/test/API/commands/frame/diagnose/bad-reference/TestBadReference.py +++ lldb/test/API/commands/frame/diagnose/bad-reference/TestBadReference.py @@ -17,7 +17,7 @@ def test_bad_reference(self): TestBase.setUp(self) self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) self.runCmd("run", RUN_SUCCEEDED) self.expect("thread list", "Thread should be stopped", Index: lldb/test/API/commands/frame/diagnose/complicated-expression/TestComplicatedExpression.py =================================================================== --- lldb/test/API/commands/frame/diagnose/complicated-expression/TestComplicatedExpression.py +++ lldb/test/API/commands/frame/diagnose/complicated-expression/TestComplicatedExpression.py @@ -17,7 +17,7 @@ def test_diagnose_dereference_argument(self): TestBase.setUp(self) self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) self.runCmd("run", RUN_SUCCEEDED) self.expect("thread list", "Thread should be stopped", Index: lldb/test/API/commands/frame/diagnose/dereference-argument/TestDiagnoseDereferenceArgument.py =================================================================== --- lldb/test/API/commands/frame/diagnose/dereference-argument/TestDiagnoseDereferenceArgument.py +++ lldb/test/API/commands/frame/diagnose/dereference-argument/TestDiagnoseDereferenceArgument.py @@ -17,7 +17,7 @@ def test_diagnose_dereference_argument(self): TestBase.setUp(self) self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) self.runCmd("run", RUN_SUCCEEDED) self.expect("thread list", "Thread should be stopped", Index: lldb/test/API/commands/frame/diagnose/dereference-function-return/TestDiagnoseDereferenceFunctionReturn.py =================================================================== --- lldb/test/API/commands/frame/diagnose/dereference-function-return/TestDiagnoseDereferenceFunctionReturn.py +++ lldb/test/API/commands/frame/diagnose/dereference-function-return/TestDiagnoseDereferenceFunctionReturn.py @@ -18,7 +18,7 @@ def test_diagnose_dereference_function_return(self): TestBase.setUp(self) self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) self.runCmd("run", RUN_SUCCEEDED) self.expect("thread list", "Thread should be stopped", Index: lldb/test/API/commands/frame/diagnose/dereference-this/TestDiagnoseDereferenceThis.py =================================================================== --- lldb/test/API/commands/frame/diagnose/dereference-this/TestDiagnoseDereferenceThis.py +++ lldb/test/API/commands/frame/diagnose/dereference-this/TestDiagnoseDereferenceThis.py @@ -17,7 +17,7 @@ def test_diagnose_dereference_this(self): TestBase.setUp(self) self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) self.runCmd("run", RUN_SUCCEEDED) self.expect("thread list", "Thread should be stopped", Index: lldb/test/API/commands/frame/diagnose/inheritance/TestDiagnoseInheritance.py =================================================================== --- lldb/test/API/commands/frame/diagnose/inheritance/TestDiagnoseInheritance.py +++ lldb/test/API/commands/frame/diagnose/inheritance/TestDiagnoseInheritance.py @@ -17,7 +17,7 @@ def test_diagnose_inheritance(self): TestBase.setUp(self) self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) self.runCmd("run", RUN_SUCCEEDED) self.expect("thread list", "Thread should be stopped", Index: lldb/test/API/commands/frame/diagnose/local-variable/TestLocalVariable.py =================================================================== --- lldb/test/API/commands/frame/diagnose/local-variable/TestLocalVariable.py +++ lldb/test/API/commands/frame/diagnose/local-variable/TestLocalVariable.py @@ -17,7 +17,7 @@ def test_local_variable(self): TestBase.setUp(self) self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) self.runCmd("run", RUN_SUCCEEDED) self.expect("thread list", "Thread should be stopped", Index: lldb/test/API/commands/frame/diagnose/virtual-method-call/TestDiagnoseDereferenceVirtualMethodCall.py =================================================================== --- lldb/test/API/commands/frame/diagnose/virtual-method-call/TestDiagnoseDereferenceVirtualMethodCall.py +++ lldb/test/API/commands/frame/diagnose/virtual-method-call/TestDiagnoseDereferenceVirtualMethodCall.py @@ -17,7 +17,7 @@ def test_diagnose_virtual_method_call(self): TestBase.setUp(self) self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) self.runCmd("run", RUN_SUCCEEDED) self.expect("thread list", "Thread should be stopped", Index: lldb/test/API/commands/frame/recognizer/TestFrameRecognizer.py =================================================================== --- lldb/test/API/commands/frame/recognizer/TestFrameRecognizer.py +++ lldb/test/API/commands/frame/recognizer/TestFrameRecognizer.py @@ -18,7 +18,7 @@ @skipUnlessDarwin def test_frame_recognizer_1(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Clear internal & plugins recognizers that get initialized at launch self.runCmd("frame recognizer clear") @@ -132,7 +132,7 @@ @skipUnlessDarwin def test_frame_recognizer_multi_symbol(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Clear internal & plugins recognizers that get initialized at launch self.runCmd("frame recognizer clear") @@ -164,7 +164,7 @@ @skipUnlessDarwin def test_frame_recognizer_target_specific(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Clear internal & plugins recognizers that get initialized at launch self.runCmd("frame recognizer clear") @@ -208,7 +208,7 @@ @skipUnlessDarwin def test_frame_recognizer_not_only_first_instruction(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Clear internal & plugins recognizers that get initialized at launch. self.runCmd("frame recognizer clear") Index: lldb/test/API/commands/gui/basic/TestGuiBasic.py =================================================================== --- lldb/test/API/commands/gui/basic/TestGuiBasic.py +++ lldb/test/API/commands/gui/basic/TestGuiBasic.py @@ -19,7 +19,7 @@ def test_gui(self): self.build() - self.launch(executable=self.getBuildArtifact("a.out"), dimensions=(100,500)) + self.launch(executable=self.getTestExecutable(), dimensions=(100,500)) self.expect('br set -f main.c -p "// Break here"', substrs=["Breakpoint 1", "address ="]) self.expect("run", substrs=["stop reason ="]) Index: lldb/test/API/commands/gui/basicdebug/TestGuiBasicDebug.py =================================================================== --- lldb/test/API/commands/gui/basicdebug/TestGuiBasicDebug.py +++ lldb/test/API/commands/gui/basicdebug/TestGuiBasicDebug.py @@ -19,7 +19,7 @@ def test_gui(self): self.build() - self.launch(executable=self.getBuildArtifact("a.out"), dimensions=(100,500)) + self.launch(executable=self.getTestExecutable(), dimensions=(100,500)) self.expect('br set -f main.c -p "// Break here"', substrs=["Breakpoint 1", "address ="]) self.expect("run", substrs=["stop reason ="]) Index: lldb/test/API/commands/gui/breakpoints/TestGuiBreakpoints.py =================================================================== --- lldb/test/API/commands/gui/breakpoints/TestGuiBreakpoints.py +++ lldb/test/API/commands/gui/breakpoints/TestGuiBreakpoints.py @@ -19,7 +19,7 @@ def test_gui(self): self.build() - self.launch(executable=self.getBuildArtifact("a.out"), dimensions=(100,500)) + self.launch(executable=self.getTestExecutable(), dimensions=(100,500)) self.expect('br set -o true -f main.c -p "// First break here"', substrs=["Breakpoint 1", "address ="]) self.expect("run", substrs=["stop reason ="]) Index: lldb/test/API/commands/gui/expand-threads-tree/TestGuiExpandThreadsTree.py =================================================================== --- lldb/test/API/commands/gui/expand-threads-tree/TestGuiExpandThreadsTree.py +++ lldb/test/API/commands/gui/expand-threads-tree/TestGuiExpandThreadsTree.py @@ -21,7 +21,7 @@ def test_gui(self): self.build() - self.launch(executable=self.getBuildArtifact("a.out"), dimensions=(100,500)) + self.launch(executable=self.getTestExecutable(), dimensions=(100,500)) self.expect("breakpoint set -n break_here", substrs=["Breakpoint 1", "address ="]) self.expect("run", substrs=["stop reason ="]) Index: lldb/test/API/commands/gui/viewlarge/TestGuiViewLarge.py =================================================================== --- lldb/test/API/commands/gui/viewlarge/TestGuiViewLarge.py +++ lldb/test/API/commands/gui/viewlarge/TestGuiViewLarge.py @@ -22,7 +22,7 @@ self.build() # Limit columns to 80, so that long lines will not be displayed completely. - self.launch(executable=self.getBuildArtifact("a.out"), dimensions=(100,80)) + self.launch(executable=self.getTestExecutable(), dimensions=(100,80)) self.expect('br set -f main.c -p "// Break here"', substrs=["Breakpoint 1", "address ="]) self.expect("run", substrs=["stop reason ="]) Index: lldb/test/API/commands/log/basic/TestLogging.py =================================================================== --- lldb/test/API/commands/log/basic/TestLogging.py +++ lldb/test/API/commands/log/basic/TestLogging.py @@ -23,7 +23,7 @@ def test_file_writing(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.expect("file " + exe, patterns=["Current executable set to .*a.out"]) Index: lldb/test/API/commands/memory/write/TestMemoryWrite.py =================================================================== --- lldb/test/API/commands/memory/write/TestMemoryWrite.py +++ lldb/test/API/commands/memory/write/TestMemoryWrite.py @@ -21,7 +21,7 @@ def build_run_stop(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Break in main() after the variables are assigned values. Index: lldb/test/API/commands/platform/connect/TestPlatformConnect.py =================================================================== --- lldb/test/API/commands/platform/connect/TestPlatformConnect.py +++ lldb/test/API/commands/platform/connect/TestPlatformConnect.py @@ -28,7 +28,7 @@ "--socket-file", port_file, "--", - self.getBuildArtifact("a.out"), + self.getTestExecutable(), "foo"] self.spawnSubprocess( lldbgdbserverutils.get_lldb_server_exe(), Index: lldb/test/API/commands/process/launch/TestProcessLaunch.py =================================================================== --- lldb/test/API/commands/process/launch/TestProcessLaunch.py +++ lldb/test/API/commands/process/launch/TestProcessLaunch.py @@ -32,7 +32,7 @@ def test_io(self): """Test that process launch I/O redirection flags work properly.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.expect("file " + exe, patterns=["Current executable set to .*a.out"]) @@ -89,7 +89,7 @@ d = {'CXX_SOURCES': 'print_cwd.cpp'} self.build(dictionary=d) self.setTearDownCleanup(d) - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe) mywd = 'my_working_dir' @@ -116,7 +116,7 @@ d = {'CXX_SOURCES': 'print_cwd.cpp'} self.build(dictionary=d) self.setTearDownCleanup(d) - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe) mywd = 'my_working_dir' Index: lldb/test/API/commands/register/register/aarch64_dynamic_regset/TestArm64DynamicRegsets.py =================================================================== --- lldb/test/API/commands/register/register/aarch64_dynamic_regset/TestArm64DynamicRegsets.py +++ lldb/test/API/commands/register/register/aarch64_dynamic_regset/TestArm64DynamicRegsets.py @@ -74,7 +74,7 @@ self.build() self.line = line_number('main.c', '// Set a break point here.') - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( Index: lldb/test/API/commands/register/register/aarch64_sve_registers/rw_access_dynamic_resize/TestSVEThreadedDynamic.py =================================================================== --- lldb/test/API/commands/register/register/aarch64_sve_registers/rw_access_dynamic_resize/TestSVEThreadedDynamic.py +++ lldb/test/API/commands/register/register/aarch64_sve_registers/rw_access_dynamic_resize/TestSVEThreadedDynamic.py @@ -58,7 +58,7 @@ """Test AArch64 SVE registers multi-threaded dynamic resize. """ self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) if not self.isAArch64SVE(): Index: lldb/test/API/commands/register/register/aarch64_sve_registers/rw_access_static_config/TestSVERegisters.py =================================================================== --- lldb/test/API/commands/register/register/aarch64_sve_registers/rw_access_static_config/TestSVERegisters.py +++ lldb/test/API/commands/register/register/aarch64_sve_registers/rw_access_static_config/TestSVERegisters.py @@ -72,7 +72,7 @@ self.build() self.line = line_number('main.c', '// Set a break point here.') - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) if not self.isAArch64SVE(): @@ -127,7 +127,7 @@ self.build() self.line = line_number('main.c', '// Set a break point here.') - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) if not self.isAArch64SVE(): Index: lldb/test/API/commands/register/register/register_command/TestRegisters.py =================================================================== --- lldb/test/API/commands/register/register/register_command/TestRegisters.py +++ lldb/test/API/commands/register/register/register_command/TestRegisters.py @@ -133,7 +133,7 @@ self.convenience_registers_with_process_attach(test_16bit_regs=True) def common_setup(self): - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) @@ -465,7 +465,7 @@ def convenience_registers_with_process_attach(self, test_16bit_regs): """Test convenience registers after a 'process attach'.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Spawn a new process pid = self.spawnSubprocess(exe, ['wait_for_attach']).pid Index: lldb/test/API/commands/settings/TestSettings.py =================================================================== --- lldb/test/API/commands/settings/TestSettings.py +++ lldb/test/API/commands/settings/TestSettings.py @@ -29,7 +29,7 @@ """Test the `interpreter.repeat-previous-command` setting.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) setting = "interpreter.repeat-previous-command" @@ -147,7 +147,7 @@ """Test that 'set frame-format' with a backtick char in the format string works as well as fullpath.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) def cleanup(): @@ -184,7 +184,7 @@ """Test that after 'set auto-confirm true', manual confirmation should not kick in.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) self.runCmd("settings set auto-confirm true") @@ -209,7 +209,7 @@ """Test that user options for the disassembler take effect.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # AT&T syntax @@ -259,7 +259,7 @@ self.addTearDownHook( lambda: self.runCmd("settings clear target.env-vars")) - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) target = self.dbg.GetTargetAtIndex(0) @@ -341,7 +341,7 @@ os.environ.pop("MY_HOST_ENV_VAR2") self.addTearDownHook(unset_env_variables) - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # By default, inherit-env is 'true'. @@ -427,7 +427,7 @@ """Test that setting target.error/output-path for the launched process works.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Set the error-path and output-path and verify both are set. Index: lldb/test/API/commands/settings/quoting/TestQuoting.py =================================================================== --- lldb/test/API/commands/settings/quoting/TestQuoting.py +++ lldb/test/API/commands/settings/quoting/TestQuoting.py @@ -21,7 +21,7 @@ @no_debug_info_test def test(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # No quotes. Index: lldb/test/API/commands/statistics/basic/TestStats.py =================================================================== --- lldb/test/API/commands/statistics/basic/TestStats.py +++ lldb/test/API/commands/statistics/basic/TestStats.py @@ -264,7 +264,7 @@ Test "statistics dump" and the memory information. """ self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.createTestTarget(file_path=exe) debug_stats = self.get_stats() debug_stat_keys = [ @@ -317,7 +317,7 @@ Test "statistics dump" and the module information. """ self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.createTestTarget(file_path=exe) debug_stats = self.get_stats() debug_stat_keys = [ Index: lldb/test/API/commands/target/auto-install-main-executable/TestAutoInstallMainExecutable.py =================================================================== --- lldb/test/API/commands/target/auto-install-main-executable/TestAutoInstallMainExecutable.py +++ lldb/test/API/commands/target/auto-install-main-executable/TestAutoInstallMainExecutable.py @@ -68,6 +68,6 @@ # Create the target with the original file. self.runCmd("target create --remote-file %s %s "% (dest.fullpath, - self.getBuildArtifact("a.out"))) + self.getTestExecutable())) self.expect("process launch", substrs=["exited with status = 74"]) Index: lldb/test/API/commands/target/basic/TestTargetCommand.py =================================================================== --- lldb/test/API/commands/target/basic/TestTargetCommand.py +++ lldb/test/API/commands/target/basic/TestTargetCommand.py @@ -64,7 +64,7 @@ def do_target_command(self): """Exercise 'target create', 'target list', 'target select' commands.""" - exe_a = self.getBuildArtifact("a.out") + exe_a = self.getTestExecutable() exe_b = self.getBuildArtifact("b.out") exe_c = self.getBuildArtifact("c.out") @@ -117,7 +117,7 @@ @no_debug_info_test def test_target_create_invalid_arch(self): - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.expect("target create {} --arch doesntexist".format(exe), error=True, patterns=["error: invalid triple 'doesntexist'"]) @@ -391,7 +391,7 @@ @no_debug_info_test def test_target_delete_all(self): self.buildAll() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) self.runCmd("file " + self.getBuildArtifact("b.out"), CURRENT_EXECUTABLE_SET) self.expect("target delete --all") self.expect("target list", substrs=["No targets."]) @@ -399,7 +399,7 @@ @no_debug_info_test def test_target_delete_by_index(self): self.buildAll() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) self.runCmd("file " + self.getBuildArtifact("b.out"), CURRENT_EXECUTABLE_SET) self.runCmd("file " + self.getBuildArtifact("c.out"), CURRENT_EXECUTABLE_SET) self.expect("target delete 3", error=True, @@ -422,7 +422,7 @@ @no_debug_info_test def test_target_delete_by_index_multiple(self): self.buildAll() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) self.runCmd("file " + self.getBuildArtifact("b.out"), CURRENT_EXECUTABLE_SET) self.runCmd("file " + self.getBuildArtifact("c.out"), CURRENT_EXECUTABLE_SET) @@ -436,7 +436,7 @@ @no_debug_info_test def test_target_delete_selected(self): self.buildAll() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) self.runCmd("file " + self.getBuildArtifact("b.out"), CURRENT_EXECUTABLE_SET) self.runCmd("file " + self.getBuildArtifact("c.out"), CURRENT_EXECUTABLE_SET) self.runCmd("target select 1") Index: lldb/test/API/commands/target/create-deps/TestTargetCreateDeps.py =================================================================== --- lldb/test/API/commands/target/create-deps/TestTargetCreateDeps.py +++ lldb/test/API/commands/target/create-deps/TestTargetCreateDeps.py @@ -35,7 +35,7 @@ triple=no_match(".*-android")) def test_dependents_implicit_default_exe(self): """Test default behavior""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("target create " + exe, CURRENT_EXECUTABLE_SET) self.has_exactly_one_image(False) @@ -44,13 +44,13 @@ triple=no_match(".*-android")) def test_dependents_explicit_default_exe(self): """Test default behavior""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("target create -ddefault " + exe, CURRENT_EXECUTABLE_SET) self.has_exactly_one_image(False) def test_dependents_explicit_true_exe(self): """Test default behavior""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("target create -dtrue " + exe, CURRENT_EXECUTABLE_SET) self.has_exactly_one_image(True) @@ -59,13 +59,13 @@ triple=no_match(".*-android")) def test_dependents_explicit_false_exe(self): """Test default behavior""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("target create -dfalse " + exe, CURRENT_EXECUTABLE_SET) self.has_exactly_one_image(False) def test_dependents_implicit_false_exe(self): """Test default behavior""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("target create -d " + exe, CURRENT_EXECUTABLE_SET) self.has_exactly_one_image(True) Index: lldb/test/API/commands/target/create-no-such-arch/TestNoSuchArch.py =================================================================== --- lldb/test/API/commands/target/create-no-such-arch/TestNoSuchArch.py +++ lldb/test/API/commands/target/create-no-such-arch/TestNoSuchArch.py @@ -15,7 +15,7 @@ def test(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Check that passing an invalid arch via the command-line fails but # doesn't crash Index: lldb/test/API/commands/target/modules/search-paths/insert/TestTargetModulesSearchpathsInsert.py =================================================================== --- lldb/test/API/commands/target/modules/search-paths/insert/TestTargetModulesSearchpathsInsert.py +++ lldb/test/API/commands/target/modules/search-paths/insert/TestTargetModulesSearchpathsInsert.py @@ -10,7 +10,7 @@ @no_debug_info_test def test_invalid_arg(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.expect("target create %s" % (exe)) self.expect("target modules search-paths insert -1 a b", error=True, Index: lldb/test/API/commands/trace/multiple-threads/TestTraceStartStopMultipleThreads.py =================================================================== --- lldb/test/API/commands/trace/multiple-threads/TestTraceStartStopMultipleThreads.py +++ lldb/test/API/commands/trace/multiple-threads/TestTraceStartStopMultipleThreads.py @@ -12,7 +12,7 @@ @testSBAPIAndCommands def testStartMultipleLiveThreads(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.dbg.CreateTarget(exe) @@ -36,7 +36,7 @@ @testSBAPIAndCommands def testStartMultipleLiveThreadsWithStops(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.dbg.CreateTarget(exe) @@ -73,7 +73,7 @@ @testSBAPIAndCommands def testStartMultipleLiveThreadsWithStops(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.dbg.CreateTarget(exe) self.expect("b main") @@ -109,7 +109,7 @@ @skipIf(oslist=no_match(['linux']), archs=no_match(['i386', 'x86_64'])) def testStartMultipleLiveThreadsWithThreadStartAll(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.expect("b main") @@ -142,7 +142,7 @@ @testSBAPIAndCommands def testStartMultipleLiveThreadsWithSmallTotalLimit(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.dbg.CreateTarget(exe) @@ -165,7 +165,7 @@ self.skipIfPerCoreTracingIsNotSupported() self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.dbg.CreateTarget(exe) self.expect("b main") Index: lldb/test/API/commands/watchpoints/multi_watchpoint_slots/TestWatchpointMultipleSlots.py =================================================================== --- lldb/test/API/commands/watchpoints/multi_watchpoint_slots/TestWatchpointMultipleSlots.py +++ lldb/test/API/commands/watchpoints/multi_watchpoint_slots/TestWatchpointMultipleSlots.py @@ -24,7 +24,7 @@ self.source = 'main.c' # Output filename. - self.exe_name = self.getBuildArtifact("a.out") + self.exe_name = self.getTestExecutable() self.d = {'C_SOURCES': self.source, 'EXE': self.exe_name} # This is a arm and aarch64 specific test case. No other architectures tested. Index: lldb/test/API/commands/watchpoints/watch_tagged_addr/TestWatchTaggedAddress.py =================================================================== --- lldb/test/API/commands/watchpoints/watch_tagged_addr/TestWatchTaggedAddress.py +++ lldb/test/API/commands/watchpoints/watch_tagged_addr/TestWatchTaggedAddress.py @@ -27,7 +27,7 @@ self.build() # Get the path of the executable - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) Index: lldb/test/API/commands/watchpoints/watchpoint_on_vectors/TestValueOfVectorVariable.py =================================================================== --- lldb/test/API/commands/watchpoints/watchpoint_on_vectors/TestValueOfVectorVariable.py +++ lldb/test/API/commands/watchpoints/watchpoint_on_vectors/TestValueOfVectorVariable.py @@ -17,7 +17,7 @@ def test_value_of_vector_variable_using_watchpoint_set(self): """Test verify displayed value of vector variable.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() d = {'C_SOURCES': self.source, 'EXE': exe} self.build(dictionary=d) self.setTearDownCleanup(dictionary=d) @@ -31,7 +31,7 @@ def value_of_vector_variable_with_watchpoint_set(self): """Test verify displayed value of vector variable""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Set break to get a frame Index: lldb/test/API/commands/watchpoints/watchpoint_set_command/TestWatchLocationWithWatchSet.py =================================================================== --- lldb/test/API/commands/watchpoints/watchpoint_set_command/TestWatchLocationWithWatchSet.py +++ lldb/test/API/commands/watchpoints/watchpoint_set_command/TestWatchLocationWithWatchSet.py @@ -47,7 +47,7 @@ self.build() self.setTearDownCleanup() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Add a breakpoint to set a watchpoint when stopped on the breakpoint. Index: lldb/test/API/commands/watchpoints/watchpoint_size/TestWatchpointSizes.py =================================================================== --- lldb/test/API/commands/watchpoints/watchpoint_size/TestWatchpointSizes.py +++ lldb/test/API/commands/watchpoints/watchpoint_size/TestWatchpointSizes.py @@ -25,7 +25,7 @@ self.source = 'main.c' # Output filename. - self.exe_name = self.getBuildArtifact("a.out") + self.exe_name = self.getTestExecutable() self.d = {'C_SOURCES': self.source, 'EXE': self.exe_name} # Read-write watchpoints not supported on SystemZ Index: lldb/test/API/driver/batch_mode/TestBatchMode.py =================================================================== --- lldb/test/API/driver/batch_mode/TestBatchMode.py +++ lldb/test/API/driver/batch_mode/TestBatchMode.py @@ -22,7 +22,7 @@ """Test that the lldb driver's batch mode works correctly.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Pass CRASH so the process will crash and stop in batch mode. extra_args = ['-b', @@ -53,7 +53,7 @@ """Test that the lldb driver's batch mode works correctly.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Now do it again, and make sure if we don't crash, we quit: extra_args = ['-b', @@ -83,7 +83,7 @@ """Test that the lldb driver's batch mode works correctly for process launch.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Launch with the option '--stop-at-entry' stops with a signal (usually SIGSTOP) # that should be suppressed since it doesn't imply a crash and @@ -120,7 +120,7 @@ self.build() self.setTearDownCleanup() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Start up the process by hand, attach to it, and wait for its completion. # Attach is funny, since it looks like it stops with a signal on most Unixen so Index: lldb/test/API/functionalities/archives/TestBSDArchives.py =================================================================== --- lldb/test/API/functionalities/archives/TestBSDArchives.py +++ lldb/test/API/functionalities/archives/TestBSDArchives.py @@ -29,7 +29,7 @@ """Break inside a() and b() defined within libfoo.a.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Break inside a() by file and line first. Index: lldb/test/API/functionalities/avoids-fd-leak/TestFdLeak.py =================================================================== --- lldb/test/API/functionalities/avoids-fd-leak/TestFdLeak.py +++ lldb/test/API/functionalities/avoids-fd-leak/TestFdLeak.py @@ -34,7 +34,7 @@ def do_test(self, commands): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() for c in commands: self.runCmd(c) @@ -59,7 +59,7 @@ @skipIfDarwinEmbedded # # debugserver on ios has an extra fd open on launch def test_fd_leak_multitarget(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) breakpoint = target.BreakpointCreateBySourceRegex( Index: lldb/test/API/functionalities/breakpoint/breakpoint_callback_command_source/TestBreakpointCallbackCommandSource.py =================================================================== --- lldb/test/API/functionalities/breakpoint/breakpoint_callback_command_source/TestBreakpointCallbackCommandSource.py +++ lldb/test/API/functionalities/breakpoint/breakpoint_callback_command_source/TestBreakpointCallbackCommandSource.py @@ -23,7 +23,7 @@ @skipIf(oslist=["freebsd"], bugnumber="llvm.org/pr48316") def test_breakpoint_callback_command_source(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.launch(exe) self.expect("b main", substrs=["Breakpoint 1"]) Index: lldb/test/API/functionalities/breakpoint/breakpoint_command/TestBreakpointCommand.py =================================================================== --- lldb/test/API/functionalities/breakpoint/breakpoint_command/TestBreakpointCommand.py +++ lldb/test/API/functionalities/breakpoint/breakpoint_command/TestBreakpointCommand.py @@ -45,7 +45,7 @@ def test_delete_all_breakpoints(self): """Test that deleting all breakpoints works.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_symbol(self, "main") @@ -62,7 +62,7 @@ def breakpoint_command_sequence(self): """Test a sequence of breakpoint command add, list, and delete.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Add three breakpoints on the same line. The first time we don't specify the file, @@ -246,7 +246,7 @@ def breakpoint_command_script_parameters(self): """Test that the frame and breakpoint location are being properly passed to the script breakpoint command function.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Add a breakpoint. Index: lldb/test/API/functionalities/breakpoint/breakpoint_command/TestRegexpBreakCommand.py =================================================================== --- lldb/test/API/functionalities/breakpoint/breakpoint_command/TestRegexpBreakCommand.py +++ lldb/test/API/functionalities/breakpoint/breakpoint_command/TestRegexpBreakCommand.py @@ -29,7 +29,7 @@ def regexp_break_command(self): """Test the super consie "b" command, which is analias for _regexp-break.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) break_results = lldbutil.run_break_set_command( Index: lldb/test/API/functionalities/breakpoint/breakpoint_conditions/TestBreakpointConditions.py =================================================================== --- lldb/test/API/functionalities/breakpoint/breakpoint_conditions/TestBreakpointConditions.py +++ lldb/test/API/functionalities/breakpoint/breakpoint_conditions/TestBreakpointConditions.py @@ -45,7 +45,7 @@ def breakpoint_conditions(self, inline=False): """Exercise breakpoint condition with 'breakpoint modify -c id'.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) if inline: @@ -182,7 +182,7 @@ def breakpoint_invalid_conditions_python(self): """Use Python APIs to set breakpoint conditions.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) Index: lldb/test/API/functionalities/breakpoint/breakpoint_ids/TestBreakpointIDs.py =================================================================== --- lldb/test/API/functionalities/breakpoint/breakpoint_ids/TestBreakpointIDs.py +++ lldb/test/API/functionalities/breakpoint/breakpoint_ids/TestBreakpointIDs.py @@ -16,7 +16,7 @@ def test(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.expect("file " + exe, patterns=["Current executable set to .*a.out"]) Index: lldb/test/API/functionalities/breakpoint/breakpoint_ignore_count/TestBreakpointIgnoreCount.py =================================================================== --- lldb/test/API/functionalities/breakpoint/breakpoint_ignore_count/TestBreakpointIgnoreCount.py +++ lldb/test/API/functionalities/breakpoint/breakpoint_ignore_count/TestBreakpointIgnoreCount.py @@ -55,7 +55,7 @@ def breakpoint_ignore_count(self): """Exercise breakpoint ignore count with 'breakpoint set -i '.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Create a breakpoint in main.c at line1. Index: lldb/test/API/functionalities/breakpoint/breakpoint_in_delayslot/TestAvoidBreakpointInDelaySlot.py =================================================================== --- lldb/test/API/functionalities/breakpoint/breakpoint_in_delayslot/TestAvoidBreakpointInDelaySlot.py +++ lldb/test/API/functionalities/breakpoint/breakpoint_in_delayslot/TestAvoidBreakpointInDelaySlot.py @@ -19,7 +19,7 @@ @skipIf(archs=no_match(re.compile('mips*'))) def test(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.expect("file " + exe, patterns=["Current executable set to .*a.out.*"]) Index: lldb/test/API/functionalities/breakpoint/breakpoint_language/TestBreakpointLanguage.py =================================================================== --- lldb/test/API/functionalities/breakpoint/breakpoint_language/TestBreakpointLanguage.py +++ lldb/test/API/functionalities/breakpoint/breakpoint_language/TestBreakpointLanguage.py @@ -26,7 +26,7 @@ self.build() # Create a target by the debugger. - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() error = lldb.SBError() # Don't read in dependencies so we don't come across false matches that # add unwanted breakpoint hits. @@ -67,7 +67,7 @@ self.build() # Create a target by the debugger. - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() error = lldb.SBError() # Don't read in dependencies so we don't come across false matches that # add unwanted breakpoint hits. Index: lldb/test/API/functionalities/breakpoint/breakpoint_locations/TestBreakpointLocations.py =================================================================== --- lldb/test/API/functionalities/breakpoint/breakpoint_locations/TestBreakpointLocations.py +++ lldb/test/API/functionalities/breakpoint/breakpoint_locations/TestBreakpointLocations.py @@ -37,7 +37,7 @@ self.line = line_number('main.c', '// Set break point at this line.') def set_breakpoint (self): - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, "Target %s is not valid"%(exe)) Index: lldb/test/API/functionalities/breakpoint/breakpoint_names/TestBreakpointNames.py =================================================================== --- lldb/test/API/functionalities/breakpoint/breakpoint_names/TestBreakpointNames.py +++ lldb/test/API/functionalities/breakpoint/breakpoint_names/TestBreakpointNames.py @@ -55,7 +55,7 @@ self.do_check_configuring_permissions_cli() def setup_target(self): - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a targets we are making breakpoint in and copying to: self.target = self.dbg.CreateTarget(exe) Index: lldb/test/API/functionalities/breakpoint/breakpoint_options/TestBreakpointOptions.py =================================================================== --- lldb/test/API/functionalities/breakpoint/breakpoint_options/TestBreakpointOptions.py +++ lldb/test/API/functionalities/breakpoint/breakpoint_options/TestBreakpointOptions.py @@ -26,7 +26,7 @@ def breakpoint_options_test(self): """Test breakpoint command for different options.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # This should create a breakpoint with 1 locations. @@ -76,7 +76,7 @@ def breakpoint_options_language_test(self): """Test breakpoint command for language option.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # This should create a breakpoint with 1 locations. Index: lldb/test/API/functionalities/breakpoint/breakpoint_set_restart/TestBreakpointSetRestart.py =================================================================== --- lldb/test/API/functionalities/breakpoint/breakpoint_set_restart/TestBreakpointSetRestart.py +++ lldb/test/API/functionalities/breakpoint/breakpoint_set_restart/TestBreakpointSetRestart.py @@ -16,7 +16,7 @@ def test_breakpoint_set_restart(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/functionalities/breakpoint/cpp/TestCPPBreakpointLocations.py =================================================================== --- lldb/test/API/functionalities/breakpoint/cpp/TestCPPBreakpointLocations.py +++ lldb/test/API/functionalities/breakpoint/cpp/TestCPPBreakpointLocations.py @@ -43,7 +43,7 @@ def breakpoint_id_tests(self): # Create a target by the debugger. - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) bp_dicts = [ @@ -67,7 +67,7 @@ @expectedFailureAll(oslist=["windows"], bugnumber="llvm.org/pr24764") def test_destructors(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) # Don't skip prologue, so we can check the breakpoint address more Index: lldb/test/API/functionalities/breakpoint/cpp_exception/TestCPPExceptionBreakpoint.py =================================================================== --- lldb/test/API/functionalities/breakpoint/cpp_exception/TestCPPExceptionBreakpoint.py +++ lldb/test/API/functionalities/breakpoint/cpp_exception/TestCPPExceptionBreakpoint.py @@ -35,7 +35,7 @@ self.main_source_spec = lldb.SBFileSpec(self.main_source) def do_cpp_exception_bkpt(self): - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() error = lldb.SBError() self.target = self.dbg.CreateTarget(exe) @@ -57,7 +57,7 @@ "One thread stopped at the exception breakpoint.") def do_dummy_target_cpp_exception_bkpt(self): - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() error = lldb.SBError() dummy_exception_bkpt = self.dbg.GetDummyTarget().BreakpointCreateForException( Index: lldb/test/API/functionalities/breakpoint/debugbreak/TestDebugBreak.py =================================================================== --- lldb/test/API/functionalities/breakpoint/debugbreak/TestDebugBreak.py +++ lldb/test/API/functionalities/breakpoint/debugbreak/TestDebugBreak.py @@ -18,7 +18,7 @@ def test_asm_int_3(self): """Test that intrinsics like `__debugbreak();` and `asm {"int3"}` are treated like breakpoints.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Run the program. target = self.dbg.CreateTarget(exe) Index: lldb/test/API/functionalities/breakpoint/dummy_target_breakpoints/TestBreakpointsWithNoTargets.py =================================================================== --- lldb/test/API/functionalities/breakpoint/dummy_target_breakpoints/TestBreakpointsWithNoTargets.py +++ lldb/test/API/functionalities/breakpoint/dummy_target_breakpoints/TestBreakpointsWithNoTargets.py @@ -43,7 +43,7 @@ # Execute the cleanup function during test case tear down. self.addTearDownHook(cleanup) - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # The breakpoint list should show 3 locations. Index: lldb/test/API/functionalities/breakpoint/global_constructor/TestBreakpointInGlobalConstructor.py =================================================================== --- lldb/test/API/functionalities/breakpoint/global_constructor/TestBreakpointInGlobalConstructor.py +++ lldb/test/API/functionalities/breakpoint/global_constructor/TestBreakpointInGlobalConstructor.py @@ -20,7 +20,7 @@ self.line_foo = line_number('foo.cpp', '// !BR_foo') self.line_main = line_number('main.cpp', '// !BR_main') - target = self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + target = self.dbg.CreateTarget(self.getTestExecutable()) self.assertTrue(target, VALID_TARGET) env= self.registerSharedLibrariesWithTarget(target, ["foo"]) Index: lldb/test/API/functionalities/breakpoint/hardware_breakpoints/base.py =================================================================== --- lldb/test/API/functionalities/breakpoint/hardware_breakpoints/base.py +++ lldb/test/API/functionalities/breakpoint/hardware_breakpoints/base.py @@ -10,7 +10,7 @@ def supports_hw_breakpoints(self): self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) self.runCmd("breakpoint set -b main --hardware") self.runCmd("run") Index: lldb/test/API/functionalities/breakpoint/hardware_breakpoints/hardware_breakpoint_on_multiple_threads/TestHWBreakMultiThread.py =================================================================== --- lldb/test/API/functionalities/breakpoint/hardware_breakpoints/hardware_breakpoint_on_multiple_threads/TestHWBreakMultiThread.py +++ lldb/test/API/functionalities/breakpoint/hardware_breakpoints/hardware_breakpoint_on_multiple_threads/TestHWBreakMultiThread.py @@ -42,7 +42,7 @@ def break_multi_thread(self, removal_type): """Test that lldb hardware breakpoints work for multiple threads.""" - self.runCmd("file " + self.getBuildArtifact("a.out"), + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) # Stop in main before creating any threads. Index: lldb/test/API/functionalities/breakpoint/hardware_breakpoints/require_hw_breakpoints/TestRequireHWBreakpoints.py =================================================================== --- lldb/test/API/functionalities/breakpoint/hardware_breakpoints/require_hw_breakpoints/TestRequireHWBreakpoints.py +++ lldb/test/API/functionalities/breakpoint/hardware_breakpoints/require_hw_breakpoints/TestRequireHWBreakpoints.py @@ -20,7 +20,7 @@ def test_breakpoint(self): """Test regular breakpoints when hardware breakpoints are required.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.runCmd("settings set target.require-hardware-breakpoint true") Index: lldb/test/API/functionalities/breakpoint/hardware_breakpoints/write_memory_with_hw_breakpoint/TestWriteMemoryWithHWBreakpoint.py =================================================================== --- lldb/test/API/functionalities/breakpoint/hardware_breakpoints/write_memory_with_hw_breakpoint/TestWriteMemoryWithHWBreakpoint.py +++ lldb/test/API/functionalities/breakpoint/hardware_breakpoints/write_memory_with_hw_breakpoint/TestWriteMemoryWithHWBreakpoint.py @@ -20,7 +20,7 @@ @skipTestIfFn(does_not_support_hw_breakpoints) def test_copy_memory_with_hw_break(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) Index: lldb/test/API/functionalities/breakpoint/inlined_breakpoints/TestInlinedBreakpoints.py =================================================================== --- lldb/test/API/functionalities/breakpoint/inlined_breakpoints/TestInlinedBreakpoints.py +++ lldb/test/API/functionalities/breakpoint/inlined_breakpoints/TestInlinedBreakpoints.py @@ -30,7 +30,7 @@ def inlined_breakpoints(self): """Test 'b basic_types.cpp:176' does break (where int.cpp includes basic_type.cpp).""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # With the inline-breakpoint-strategy, our file+line breakpoint should Index: lldb/test/API/functionalities/breakpoint/move_nearest/TestMoveNearest.py =================================================================== --- lldb/test/API/functionalities/breakpoint/move_nearest/TestMoveNearest.py +++ lldb/test/API/functionalities/breakpoint/move_nearest/TestMoveNearest.py @@ -26,7 +26,7 @@ """Test target.move-to-nearest logic""" self.build() - target = self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + target = self.dbg.CreateTarget(self.getTestExecutable()) self.assertTrue(target, VALID_TARGET) lldbutil.run_break_set_by_symbol(self, 'main', sym_exact=True) Index: lldb/test/API/functionalities/breakpoint/objc/TestObjCBreakpoints.py =================================================================== --- lldb/test/API/functionalities/breakpoint/objc/TestObjCBreakpoints.py +++ lldb/test/API/functionalities/breakpoint/objc/TestObjCBreakpoints.py @@ -70,7 +70,7 @@ self.dbg.SetAsync(False) # Create a target by the debugger. - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.target = self.dbg.CreateTarget(exe) self.assertTrue(self.target, VALID_TARGET) Index: lldb/test/API/functionalities/breakpoint/serialize/TestBreakpointSerialization.py =================================================================== --- lldb/test/API/functionalities/breakpoint/serialize/TestBreakpointSerialization.py +++ lldb/test/API/functionalities/breakpoint/serialize/TestBreakpointSerialization.py @@ -97,7 +97,7 @@ self.addTearDownHook(cleanup) self.RemoveTempFile(self.bkpts_file_path) - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create the targets we are making breakpoints in and copying them to: self.orig_target = self.dbg.CreateTarget(exe) Index: lldb/test/API/functionalities/breakpoint/source_regexp/TestSourceRegexBreakpoints.py =================================================================== --- lldb/test/API/functionalities/breakpoint/source_regexp/TestSourceRegexBreakpoints.py +++ lldb/test/API/functionalities/breakpoint/source_regexp/TestSourceRegexBreakpoints.py @@ -25,7 +25,7 @@ def source_regex_locations(self): """ Test that restricting source expressions to files & to functions. """ # Create a target by the debugger. - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) @@ -61,7 +61,7 @@ def source_regex_restrictions(self): """ Test that restricting source expressions to files & to functions. """ # Create a target by the debugger. - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/functionalities/breakpoint/step_over_breakpoint/TestStepOverBreakpoint.py =================================================================== --- lldb/test/API/functionalities/breakpoint/step_over_breakpoint/TestStepOverBreakpoint.py +++ lldb/test/API/functionalities/breakpoint/step_over_breakpoint/TestStepOverBreakpoint.py @@ -20,7 +20,7 @@ TestBase.setUp(self) self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() src = lldb.SBFileSpec("main.cpp") # Create a target by the debugger. Index: lldb/test/API/functionalities/completion/TestCompletion.py =================================================================== --- lldb/test/API/functionalities/completion/TestCompletion.py +++ lldb/test/API/functionalities/completion/TestCompletion.py @@ -137,7 +137,7 @@ # to us here. self.build() server = self.spawnSubprocess( - self.getBuildArtifact("a.out"), + self.getTestExecutable(), ["-x"], # Arg "-x" makes the subprocess wait for input thus it won't be terminated too early install_remote=False) self.assertIsNotNone(server) @@ -434,14 +434,14 @@ def test_target_modules_dump_line_table(self): """Tests source file completion by completing the line-table argument.""" self.build() - self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + self.dbg.CreateTarget(self.getTestExecutable()) self.complete_from_to('target modules dump line-table main.cp', ['main.cpp']) def test_target_modules_load_aout(self): """Tests modules completion by completing the target modules load argument.""" self.build() - self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + self.dbg.CreateTarget(self.getTestExecutable()) self.complete_from_to('target modules load a.ou', ['a.out']) @@ -576,7 +576,7 @@ @expectedFailureAll(oslist=["windows"], bugnumber="llvm.org/pr24489") def test_symbol_name(self): self.build() - self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + self.dbg.CreateTarget(self.getTestExecutable()) self.complete_from_to('breakpoint set -n Fo', 'breakpoint set -n Foo::Bar(int,\\ int)', turn_off_re_match=True) @@ -676,7 +676,7 @@ 'target stop-hook ' + subcommand + ' ') self.build() - self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + self.dbg.CreateTarget(self.getTestExecutable()) self.runCmd('target stop-hook add test DONE') for subcommand in subcommands: @@ -693,7 +693,7 @@ def test_target_modules_load_dash_u(self): self.build() - target = self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + target = self.dbg.CreateTarget(self.getTestExecutable()) self.complete_from_to('target modules load -u ', [target.GetModuleAtIndex(0).GetUUIDString()]) def test_complete_breakpoint_with_ids(self): Index: lldb/test/API/functionalities/conditional_break/TestConditionalBreak.py =================================================================== --- lldb/test/API/functionalities/conditional_break/TestConditionalBreak.py +++ lldb/test/API/functionalities/conditional_break/TestConditionalBreak.py @@ -33,7 +33,7 @@ def do_conditional_break(self): """Exercise some thread and frame APIs to break if c() is called by a().""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) @@ -106,9 +106,9 @@ if not self.TraceOn(): self.HideStdout() - # Separate out the "file " + self.getBuildArtifact("a.out") command from .lldb file, for the sake of + # Separate out the "file " + self.getTestExecutable() command from .lldb file, for the sake of # remote testsuite. - self.runCmd("file " + self.getBuildArtifact("a.out")) + self.runCmd("file " + self.getTestExecutable()) self.runCmd("command source .lldb") self.runCmd("break list") Index: lldb/test/API/functionalities/data-formatter/boolreference/TestFormattersBoolRefPtr.py =================================================================== --- lldb/test/API/functionalities/data-formatter/boolreference/TestFormattersBoolRefPtr.py +++ lldb/test/API/functionalities/data-formatter/boolreference/TestFormattersBoolRefPtr.py @@ -28,7 +28,7 @@ def boolrefptr_data_formatter_commands(self): """Test the formatters we use for BOOL& and BOOL* in Objective-C.""" - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.mm", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/compactvectors/TestCompactVectors.py =================================================================== --- lldb/test/API/functionalities/data-formatter/compactvectors/TestCompactVectors.py +++ lldb/test/API/functionalities/data-formatter/compactvectors/TestCompactVectors.py @@ -24,7 +24,7 @@ def test_with_run_command(self): """Test that that file and class static variables display correctly.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/data-formatter-advanced/TestDataFormatterAdv.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-advanced/TestDataFormatterAdv.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-advanced/TestDataFormatterAdv.py @@ -22,7 +22,7 @@ def test_with_run_command(self): """Test that that file and class static variables display correctly.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/data-formatter-categories/TestDataFormatterCategories.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-categories/TestDataFormatterCategories.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-categories/TestDataFormatterCategories.py @@ -22,7 +22,7 @@ def test_with_run_command(self): """Test that that file and class static variables display correctly.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/data-formatter-cpp/TestDataFormatterCpp.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-cpp/TestDataFormatterCpp.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-cpp/TestDataFormatterCpp.py @@ -23,7 +23,7 @@ def test_with_run_command(self): """Test that that file and class static variables display correctly.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/data-formatter-disabling/TestDataFormatterDisabling.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-disabling/TestDataFormatterDisabling.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-disabling/TestDataFormatterDisabling.py @@ -26,7 +26,7 @@ def test_with_run_command(self): """Check that we can properly disable all data formatter categories.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/data-formatter-enum-format/TestDataFormatterEnumFormat.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-enum-format/TestDataFormatterEnumFormat.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-enum-format/TestDataFormatterEnumFormat.py @@ -22,7 +22,7 @@ def test_with_run_command(self): """Test that that file and class static variables display correctly.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/data-formatter-globals/TestDataFormatterGlobals.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-globals/TestDataFormatterGlobals.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-globals/TestDataFormatterGlobals.py @@ -23,7 +23,7 @@ def test_with_run_command(self): """Test that that file and class static variables display correctly.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/data-formatter-named-summaries/TestDataFormatterNamedSummaries.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-named-summaries/TestDataFormatterNamedSummaries.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-named-summaries/TestDataFormatterNamedSummaries.py @@ -22,7 +22,7 @@ def test_with_run_command(self): """Test that that file and class static variables display correctly.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/data-formatter-objc/cmtime/TestDataFormatterCMTime.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-objc/cmtime/TestDataFormatterCMTime.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-objc/cmtime/TestDataFormatterCMTime.py @@ -14,7 +14,7 @@ def test_nsindexpath_with_run_command(self): """Test formatters for CMTime.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) line = line_number('main.m', '// break here') Index: lldb/test/API/functionalities/data-formatter/data-formatter-objc/nsindexpath/TestDataFormatterNSIndexPath.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-objc/nsindexpath/TestDataFormatterNSIndexPath.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-objc/nsindexpath/TestDataFormatterNSIndexPath.py @@ -17,7 +17,7 @@ def appkit_tester_impl(self, commands): self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.m", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/data-formatter-objc/nsstring/TestDataFormatterNSString.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-objc/nsstring/TestDataFormatterNSString.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-objc/nsstring/TestDataFormatterNSString.py @@ -17,7 +17,7 @@ def appkit_tester_impl(self, commands): self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.m", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/data-formatter-proper-plurals/TestFormattersOneIsSingular.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-proper-plurals/TestFormattersOneIsSingular.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-proper-plurals/TestFormattersOneIsSingular.py @@ -28,7 +28,7 @@ def oneness_data_formatter_commands(self): """Test that 1 item is not as reported as 1 items.""" - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.m", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/data-formatter-ptr-to-array/TestPtrToArrayFormatting.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-ptr-to-array/TestPtrToArrayFormatting.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-ptr-to-array/TestPtrToArrayFormatting.py @@ -26,7 +26,7 @@ def data_formatter_commands(self): """Test that LLDB handles the clang typeclass Paren correctly.""" - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/data-formatter-python-synth/TestDataFormatterPythonSynth.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-python-synth/TestDataFormatterPythonSynth.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-python-synth/TestDataFormatterPythonSynth.py @@ -264,7 +264,7 @@ def rdar10960550_formatter_commands(self): """Test that synthetic children persist stoppoints.""" - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) # The second breakpoint is on a multi-line expression, so the comment # can't be on the right line... Index: lldb/test/API/functionalities/data-formatter/data-formatter-script/TestDataFormatterScript.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-script/TestDataFormatterScript.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-script/TestDataFormatterScript.py @@ -26,7 +26,7 @@ def data_formatter_commands(self): """Test that that file and class static variables display correctly.""" - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/data-formatter-skip-summary/TestDataFormatterSkipSummary.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-skip-summary/TestDataFormatterSkipSummary.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-skip-summary/TestDataFormatterSkipSummary.py @@ -29,7 +29,7 @@ def data_formatter_commands(self): """Test that that file and class static variables display correctly.""" - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) #import lldbsuite.test.lldbutil as lldbutil lldbutil.run_break_set_by_file_and_line( Index: lldb/test/API/functionalities/data-formatter/data-formatter-smart-array/TestDataFormatterSmartArray.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-smart-array/TestDataFormatterSmartArray.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-smart-array/TestDataFormatterSmartArray.py @@ -27,7 +27,7 @@ def data_formatter_commands(self): """Test that that file and class static variables display correctly.""" - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/data-formatter-stl/generic/list/TestDataFormatterGenericList.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-stl/generic/list/TestDataFormatterGenericList.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-stl/generic/list/TestDataFormatterGenericList.py @@ -29,7 +29,7 @@ def do_test_with_run_command(self, stdlib_type): """Test that that file and class static variables display correctly.""" self.build(dictionary={stdlib_type: "1"}) - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=-1) Index: lldb/test/API/functionalities/data-formatter/data-formatter-stl/generic/list/loop/TestDataFormatterGenericListLoop.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-stl/generic/list/loop/TestDataFormatterGenericListLoop.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-stl/generic/list/loop/TestDataFormatterGenericListLoop.py @@ -20,7 +20,7 @@ def do_test_with_run_command(self, stdlib_type): self.build(dictionary={stdlib_type: "1"}) - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target and target.IsValid(), "Target is valid") Index: lldb/test/API/functionalities/data-formatter/data-formatter-stl/generic/multimap/TestDataFormatterGenericMultiMap.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-stl/generic/multimap/TestDataFormatterGenericMultiMap.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-stl/generic/multimap/TestDataFormatterGenericMultiMap.py @@ -42,7 +42,7 @@ def do_test_with_run_command(self, stdlib_type): """Test that that file and class static variables display correctly.""" self.build(dictionary={stdlib_type: "1"}) - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) bkpt = self.target().FindBreakpointByID( lldbutil.run_break_set_by_source_regexp( Index: lldb/test/API/functionalities/data-formatter/data-formatter-stl/generic/optional/TestDataFormatterGenericOptional.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-stl/generic/optional/TestDataFormatterGenericOptional.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-stl/generic/optional/TestDataFormatterGenericOptional.py @@ -22,7 +22,7 @@ self.addTearDownHook(cleanup) self.build(dictionary={stdlib_type: "1"}) - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) bkpt = self.target().FindBreakpointByID( lldbutil.run_break_set_by_source_regexp( Index: lldb/test/API/functionalities/data-formatter/data-formatter-stl/generic/unordered/TestDataFormatterGenericUnordered.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-stl/generic/unordered/TestDataFormatterGenericUnordered.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-stl/generic/unordered/TestDataFormatterGenericUnordered.py @@ -15,7 +15,7 @@ def do_test_with_run_command(self, stdlib_type): self.build(dictionary={stdlib_type: "1"}) - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_source_regexp( self, "Set break point at this line.") Index: lldb/test/API/functionalities/data-formatter/data-formatter-stl/libcxx/atomic/TestLibCxxAtomic.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-stl/libcxx/atomic/TestLibCxxAtomic.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-stl/libcxx/atomic/TestLibCxxAtomic.py @@ -26,7 +26,7 @@ def test(self): """Test that std::atomic as defined by libc++ is correctly printed by LLDB""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) bkpt = self.target().FindBreakpointByID( lldbutil.run_break_set_by_source_regexp( Index: lldb/test/API/functionalities/data-formatter/data-formatter-stl/libcxx/function/TestLibCxxFunction.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-stl/libcxx/function/TestLibCxxFunction.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-stl/libcxx/function/TestLibCxxFunction.py @@ -36,7 +36,7 @@ def test(self): """Test that std::function as defined by libc++ is correctly printed by LLDB""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) bkpt = self.target().FindBreakpointByID( lldbutil.run_break_set_by_source_regexp( Index: lldb/test/API/functionalities/data-formatter/data-formatter-stl/libcxx/initializerlist/TestInitializerList.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-stl/libcxx/initializerlist/TestInitializerList.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-stl/libcxx/initializerlist/TestInitializerList.py @@ -18,7 +18,7 @@ def test(self): """Test that that file and class static variables display correctly.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) bkpt = self.target().FindBreakpointByID( lldbutil.run_break_set_by_source_regexp( Index: lldb/test/API/functionalities/data-formatter/data-formatter-stl/libcxx/iterator/TestDataFormatterLibccIterator.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-stl/libcxx/iterator/TestDataFormatterLibccIterator.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-stl/libcxx/iterator/TestDataFormatterLibccIterator.py @@ -25,7 +25,7 @@ def test_with_run_command(self): """Test that libc++ iterators format properly.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=-1) Index: lldb/test/API/functionalities/data-formatter/data-formatter-stl/libcxx/map/TestDataFormatterLibccMap.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-stl/libcxx/map/TestDataFormatterLibccMap.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-stl/libcxx/map/TestDataFormatterLibccMap.py @@ -28,7 +28,7 @@ def test_with_run_command(self): """Test that that file and class static variables display correctly.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) bkpt = self.target().FindBreakpointByID( lldbutil.run_break_set_by_source_regexp( Index: lldb/test/API/functionalities/data-formatter/data-formatter-stl/libcxx/string_view/TestDataFormatterLibcxxStringView.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-stl/libcxx/string_view/TestDataFormatterLibcxxStringView.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-stl/libcxx/string_view/TestDataFormatterLibcxxStringView.py @@ -30,7 +30,7 @@ def test_with_run_command(self): """Test that that file and class static variables display correctly.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line1, num_expected_locations=-1) Index: lldb/test/API/functionalities/data-formatter/data-formatter-stl/libcxx/vbool/TestDataFormatterLibcxxVBool.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-stl/libcxx/vbool/TestDataFormatterLibcxxVBool.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-stl/libcxx/vbool/TestDataFormatterLibcxxVBool.py @@ -24,7 +24,7 @@ def test_with_run_command(self): """Test that that file and class static variables display correctly.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=-1) Index: lldb/test/API/functionalities/data-formatter/data-formatter-stl/libstdcpp/iterator/TestDataFormatterStdIterator.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-stl/libstdcpp/iterator/TestDataFormatterStdIterator.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-stl/libstdcpp/iterator/TestDataFormatterStdIterator.py @@ -25,7 +25,7 @@ def test_with_run_command(self): """Test that libstdcpp iterators format properly.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=-1) Index: lldb/test/API/functionalities/data-formatter/data-formatter-stl/libstdcpp/map/TestDataFormatterStdMap.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-stl/libstdcpp/map/TestDataFormatterStdMap.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-stl/libstdcpp/map/TestDataFormatterStdMap.py @@ -25,7 +25,7 @@ def test_with_run_command(self): """Test that that file and class static variables display correctly.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_source_regexp( self, "Set break point at this line.") Index: lldb/test/API/functionalities/data-formatter/data-formatter-stl/libstdcpp/smart_ptr/TestDataFormatterStdSmartPtr.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-stl/libstdcpp/smart_ptr/TestDataFormatterStdSmartPtr.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-stl/libstdcpp/smart_ptr/TestDataFormatterStdSmartPtr.py @@ -16,7 +16,7 @@ @expectedFailureAll(bugnumber="llvm.org/pr50861", compiler="gcc") def test_with_run_command(self): self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_source_regexp( self, "Set break point at this line.") Index: lldb/test/API/functionalities/data-formatter/data-formatter-stl/libstdcpp/string/TestDataFormatterStdString.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-stl/libstdcpp/string/TestDataFormatterStdString.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-stl/libstdcpp/string/TestDataFormatterStdString.py @@ -26,7 +26,7 @@ def test_with_run_command(self): """Test that that file and class static variables display correctly.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=-1) Index: lldb/test/API/functionalities/data-formatter/data-formatter-stl/libstdcpp/tuple/TestDataFormatterStdTuple.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-stl/libstdcpp/tuple/TestDataFormatterStdTuple.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-stl/libstdcpp/tuple/TestDataFormatterStdTuple.py @@ -16,7 +16,7 @@ @expectedFailureAll(bugnumber="llvm.org/pr50861", compiler="gcc") def test_with_run_command(self): self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_source_regexp( self, "Set break point at this line.") Index: lldb/test/API/functionalities/data-formatter/data-formatter-stl/libstdcpp/unique_ptr/TestDataFormatterStdUniquePtr.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-stl/libstdcpp/unique_ptr/TestDataFormatterStdUniquePtr.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-stl/libstdcpp/unique_ptr/TestDataFormatterStdUniquePtr.py @@ -17,7 +17,7 @@ @skipIf(oslist=["linux"], archs=["arm", "aarch64"]) def test_with_run_command(self): self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_source_regexp( self, "Set break point at this line.") @@ -72,7 +72,7 @@ # reference chain and that it correctly handles the different options # for the frame variable command in this case. self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_source_regexp( self, "Set break point at this line.") Index: lldb/test/API/functionalities/data-formatter/data-formatter-stl/libstdcpp/vbool/TestDataFormatterStdVBool.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-stl/libstdcpp/vbool/TestDataFormatterStdVBool.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-stl/libstdcpp/vbool/TestDataFormatterStdVBool.py @@ -24,7 +24,7 @@ def test_with_run_command(self): """Test that that file and class static variables display correctly.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=-1) Index: lldb/test/API/functionalities/data-formatter/data-formatter-stl/libstdcpp/vector/TestDataFormatterStdVector.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-stl/libstdcpp/vector/TestDataFormatterStdVector.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-stl/libstdcpp/vector/TestDataFormatterStdVector.py @@ -25,7 +25,7 @@ def test_with_run_command(self): """Test that that file and class static variables display correctly.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_source_regexp( self, "Set break point at this line.") Index: lldb/test/API/functionalities/data-formatter/data-formatter-synth/TestDataFormatterSynth.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-synth/TestDataFormatterSynth.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-synth/TestDataFormatterSynth.py @@ -22,7 +22,7 @@ def test_with_run_command(self): """Test that that file and class static variables display correctly.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/data-formatter-synthtype/TestDataFormatterSynthType.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-synthtype/TestDataFormatterSynthType.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-synthtype/TestDataFormatterSynthType.py @@ -23,7 +23,7 @@ def test_with_run_command(self): """Test using Python synthetic children provider to provide a typename.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/data-formatter-synthval/TestDataFormatterSynthVal.py =================================================================== --- lldb/test/API/functionalities/data-formatter/data-formatter-synthval/TestDataFormatterSynthVal.py +++ lldb/test/API/functionalities/data-formatter/data-formatter-synthval/TestDataFormatterSynthVal.py @@ -25,7 +25,7 @@ def test_with_run_command(self): """Test using Python synthetic children provider to provide a value.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/format-propagation/TestFormatPropagation.py =================================================================== --- lldb/test/API/functionalities/data-formatter/format-propagation/TestFormatPropagation.py +++ lldb/test/API/functionalities/data-formatter/format-propagation/TestFormatPropagation.py @@ -23,7 +23,7 @@ def test_with_run_command(self): """Check for an issue where capping does not work because the Target pointer appears to be changing behind our backs.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/frameformat_smallstruct/TestFrameFormatSmallStruct.py =================================================================== --- lldb/test/API/functionalities/data-formatter/frameformat_smallstruct/TestFrameFormatSmallStruct.py +++ lldb/test/API/functionalities/data-formatter/frameformat_smallstruct/TestFrameFormatSmallStruct.py @@ -22,7 +22,7 @@ def test_with_run_command(self): """Test that the user can input a format but it will not prevail over summary format's choices.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/hexcaps/TestDataFormatterHexCaps.py =================================================================== --- lldb/test/API/functionalities/data-formatter/hexcaps/TestDataFormatterHexCaps.py +++ lldb/test/API/functionalities/data-formatter/hexcaps/TestDataFormatterHexCaps.py @@ -22,7 +22,7 @@ def test_with_run_command(self): """Test that that file and class static variables display correctly.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/language_category_updates/TestDataFormatterLanguageCategoryUpdates.py =================================================================== --- lldb/test/API/functionalities/data-formatter/language_category_updates/TestDataFormatterLanguageCategoryUpdates.py +++ lldb/test/API/functionalities/data-formatter/language_category_updates/TestDataFormatterLanguageCategoryUpdates.py @@ -35,7 +35,7 @@ self.addTearDownHook(cleanup) self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/nsarraysynth/TestNSArraySynthetic.py =================================================================== --- lldb/test/API/functionalities/data-formatter/nsarraysynth/TestNSArraySynthetic.py +++ lldb/test/API/functionalities/data-formatter/nsarraysynth/TestNSArraySynthetic.py @@ -24,7 +24,7 @@ def test_rdar11086338_with_run_command(self): """Test that NSArray reports its synthetic children properly.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.m", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/nsdictionarysynth/TestNSDictionarySynthetic.py =================================================================== --- lldb/test/API/functionalities/data-formatter/nsdictionarysynth/TestNSDictionarySynthetic.py +++ lldb/test/API/functionalities/data-formatter/nsdictionarysynth/TestNSDictionarySynthetic.py @@ -41,7 +41,7 @@ self.run_tests() def run_tests(self): - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.m", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/nssetsynth/TestNSSetSynthetic.py =================================================================== --- lldb/test/API/functionalities/data-formatter/nssetsynth/TestNSSetSynthetic.py +++ lldb/test/API/functionalities/data-formatter/nssetsynth/TestNSSetSynthetic.py @@ -41,7 +41,7 @@ self.run_tests() def run_tests(self): - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.m", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/ostypeformatting/TestFormattersOsType.py =================================================================== --- lldb/test/API/functionalities/data-formatter/ostypeformatting/TestFormattersOsType.py +++ lldb/test/API/functionalities/data-formatter/ostypeformatting/TestFormattersOsType.py @@ -24,7 +24,7 @@ def test_ostype_with_run_command(self): """Test the formatters we use for OSType.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.mm", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/parray/TestPrintArray.py =================================================================== --- lldb/test/API/functionalities/data-formatter/parray/TestPrintArray.py +++ lldb/test/API/functionalities/data-formatter/parray/TestPrintArray.py @@ -27,7 +27,7 @@ def printarray_data_formatter_commands(self): """Test that expr -Z works""" - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/poarray/TestPrintObjectArray.py =================================================================== --- lldb/test/API/functionalities/data-formatter/poarray/TestPrintObjectArray.py +++ lldb/test/API/functionalities/data-formatter/poarray/TestPrintObjectArray.py @@ -42,7 +42,7 @@ def printarray_data_formatter_commands(self): """Test that expr -O -Z works""" - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.mm", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/ptr_ref_typedef/TestPtrRef2Typedef.py =================================================================== --- lldb/test/API/functionalities/data-formatter/ptr_ref_typedef/TestPtrRef2Typedef.py +++ lldb/test/API/functionalities/data-formatter/ptr_ref_typedef/TestPtrRef2Typedef.py @@ -22,7 +22,7 @@ def test_with_run_command(self): """Test that a pointer/reference to a typedef is formatted as we want.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/pyobjsynthprovider/TestPyObjSynthProvider.py =================================================================== --- lldb/test/API/functionalities/data-formatter/pyobjsynthprovider/TestPyObjSynthProvider.py +++ lldb/test/API/functionalities/data-formatter/pyobjsynthprovider/TestPyObjSynthProvider.py @@ -28,7 +28,7 @@ def provider_data_formatter_commands(self): """Test that the PythonObjectSyntheticChildProvider helper class works""" - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/refpointer-recursion/TestDataFormatterRefPtrRecursion.py =================================================================== --- lldb/test/API/functionalities/data-formatter/refpointer-recursion/TestDataFormatterRefPtrRecursion.py +++ lldb/test/API/functionalities/data-formatter/refpointer-recursion/TestDataFormatterRefPtrRecursion.py @@ -22,7 +22,7 @@ def test_with_run_command(self): """Test that ValueObjectPrinter does not cause an infinite loop when a reference to a struct that contains a pointer to itself is printed.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/summary-string-onfail/Test-rdar-9974002.py =================================================================== --- lldb/test/API/functionalities/data-formatter/summary-string-onfail/Test-rdar-9974002.py +++ lldb/test/API/functionalities/data-formatter/summary-string-onfail/Test-rdar-9974002.py @@ -27,7 +27,7 @@ self.skipTest( "llvm.org/pr16214 -- clang emits partial DWARF for structures referenced via typedef") - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/synthcapping/TestSyntheticCapping.py =================================================================== --- lldb/test/API/functionalities/data-formatter/synthcapping/TestSyntheticCapping.py +++ lldb/test/API/functionalities/data-formatter/synthcapping/TestSyntheticCapping.py @@ -23,7 +23,7 @@ def test_with_run_command(self): """Check for an issue where capping does not work because the Target pointer appears to be changing behind our backs.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/synthupdate/TestSyntheticFilterRecompute.py =================================================================== --- lldb/test/API/functionalities/data-formatter/synthupdate/TestSyntheticFilterRecompute.py +++ lldb/test/API/functionalities/data-formatter/synthupdate/TestSyntheticFilterRecompute.py @@ -24,7 +24,7 @@ def test_rdar12437442_with_run_command(self): """Test that we update SBValues correctly as dynamic types change.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.m", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/type_summary_list_script/TestTypeSummaryListScript.py =================================================================== --- lldb/test/API/functionalities/data-formatter/type_summary_list_script/TestTypeSummaryListScript.py +++ lldb/test/API/functionalities/data-formatter/type_summary_list_script/TestTypeSummaryListScript.py @@ -27,7 +27,7 @@ def data_formatter_commands(self): """Test printing out Python summary formatters.""" - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/user-format-vs-summary/TestUserFormatVsSummary.py =================================================================== --- lldb/test/API/functionalities/data-formatter/user-format-vs-summary/TestUserFormatVsSummary.py +++ lldb/test/API/functionalities/data-formatter/user-format-vs-summary/TestUserFormatVsSummary.py @@ -22,7 +22,7 @@ def test_with_run_command(self): """Test that the user can input a format but it will not prevail over summary format's choices.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/var-in-aggregate-misuse/TestVarInAggregateMisuse.py =================================================================== --- lldb/test/API/functionalities/data-formatter/var-in-aggregate-misuse/TestVarInAggregateMisuse.py +++ lldb/test/API/functionalities/data-formatter/var-in-aggregate-misuse/TestVarInAggregateMisuse.py @@ -22,7 +22,7 @@ def test_with_run_command(self): """Test that that file and class static variables display correctly.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/varscript_formatting/TestDataFormatterVarScriptFormatting.py =================================================================== --- lldb/test/API/functionalities/data-formatter/varscript_formatting/TestDataFormatterVarScriptFormatting.py +++ lldb/test/API/functionalities/data-formatter/varscript_formatting/TestDataFormatterVarScriptFormatting.py @@ -23,7 +23,7 @@ def test_with_run_command(self): """Test using Python synthetic children provider.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/data-formatter/vector-types/TestVectorTypesFormatting.py =================================================================== --- lldb/test/API/functionalities/data-formatter/vector-types/TestVectorTypesFormatting.py +++ lldb/test/API/functionalities/data-formatter/vector-types/TestVectorTypesFormatting.py @@ -26,7 +26,7 @@ def test_with_run_command(self): """Check that vector types format properly""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/dead-strip/TestDeadStrip.py =================================================================== --- lldb/test/API/functionalities/dead-strip/TestDeadStrip.py +++ lldb/test/API/functionalities/dead-strip/TestDeadStrip.py @@ -18,7 +18,7 @@ def test(self): """Test breakpoint works correctly with dead-code stripping.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Break by function name f1 (live code). Index: lldb/test/API/functionalities/deleted-executable/TestDeletedExecutable.py =================================================================== --- lldb/test/API/functionalities/deleted-executable/TestDeletedExecutable.py +++ lldb/test/API/functionalities/deleted-executable/TestDeletedExecutable.py @@ -21,7 +21,7 @@ # determining the architecture of the process fails def test(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Use a file as a synchronization point between test and inferior. pid_file_path = lldbutil.append_to_process_working_directory(self, Index: lldb/test/API/functionalities/dyld-exec-linux/TestDyldExecLinux.py =================================================================== --- lldb/test/API/functionalities/dyld-exec-linux/TestDyldExecLinux.py +++ lldb/test/API/functionalities/dyld-exec-linux/TestDyldExecLinux.py @@ -20,7 +20,7 @@ self.build() # Extracts path of the interpreter. - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() spec = lldb.SBModuleSpec() spec.SetFileSpec(lldb.SBFileSpec(exe)) Index: lldb/test/API/functionalities/dyld-launch-linux/TestDyldLaunchLinux.py =================================================================== --- lldb/test/API/functionalities/dyld-launch-linux/TestDyldLaunchLinux.py +++ lldb/test/API/functionalities/dyld-launch-linux/TestDyldLaunchLinux.py @@ -19,7 +19,7 @@ # Extracts path of the interpreter. spec = lldb.SBModuleSpec() - spec.SetFileSpec(lldb.SBFileSpec(self.getBuildArtifact("a.out"))) + spec.SetFileSpec(lldb.SBFileSpec(self.getTestExecutable())) interp_section = lldb.SBModule(spec).FindSection(".interp") if not interp_section: return @@ -36,7 +36,7 @@ # main. Both of them will be pending breakpoints. breakpoint_main = target.BreakpointCreateBySourceRegex("// Break here", lldb.SBFileSpec("main.cpp")) breakpoint_shared_library = target.BreakpointCreateBySourceRegex("get_signal_crash", lldb.SBFileSpec("signal_file.cpp")) - launch_info = lldb.SBLaunchInfo([ "--library-path", self.get_process_working_directory(), self.getBuildArtifact("a.out")]) + launch_info = lldb.SBLaunchInfo([ "--library-path", self.get_process_working_directory(), self.getTestExecutable()]) launch_info.SetWorkingDirectory(self.get_process_working_directory()) error = lldb.SBError() process = target.Launch(launch_info, error) Index: lldb/test/API/functionalities/dynamic_value_child_count/TestDynamicValueChildCount.py =================================================================== --- lldb/test/API/functionalities/dynamic_value_child_count/TestDynamicValueChildCount.py +++ lldb/test/API/functionalities/dynamic_value_child_count/TestDynamicValueChildCount.py @@ -35,7 +35,7 @@ """Test fetching C++ dynamic values from pointers & references.""" """Get argument vals for the call stack when stopped on a breakpoint.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target from the debugger. Index: lldb/test/API/functionalities/exec/TestExec.py =================================================================== --- lldb/test/API/functionalities/exec/TestExec.py +++ lldb/test/API/functionalities/exec/TestExec.py @@ -38,7 +38,7 @@ def do_test(self, skip_exec): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() secondprog = self.getBuildArtifact("secondprog") # Create the target @@ -130,7 +130,7 @@ ''' self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) (target, process, thread, breakpoint1) = lldbutil.run_to_source_breakpoint( Index: lldb/test/API/functionalities/fat_archives/TestFatArchives.py =================================================================== --- lldb/test/API/functionalities/fat_archives/TestFatArchives.py +++ lldb/test/API/functionalities/fat_archives/TestFatArchives.py @@ -30,7 +30,7 @@ DWARF in .o file debugging. The only thing this test needs to do is to compile and set a breakpoint in the target and verify any breakpoint locations have valid debug info for the function, and source file and line.''' - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create the target target = self.dbg.CreateTarget(exe) Index: lldb/test/API/functionalities/find-line-entry/TestFindLineEntry.py =================================================================== --- lldb/test/API/functionalities/find-line-entry/TestFindLineEntry.py +++ lldb/test/API/functionalities/find-line-entry/TestFindLineEntry.py @@ -13,7 +13,7 @@ def test_compile_unit_find_line_entry_index(self): """ Test the CompileUnit LineEntryIndex lookup API """ self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.target = self.dbg.CreateTarget(exe) self.assertTrue(self.target.IsValid(), "Target is not valid") Index: lldb/test/API/functionalities/gdb_remote_client/TestPlatformKill.py =================================================================== --- lldb/test/API/functionalities/gdb_remote_client/TestPlatformKill.py +++ lldb/test/API/functionalities/gdb_remote_client/TestPlatformKill.py @@ -15,7 +15,7 @@ """Test connecting to a remote linux platform""" self.build(dictionary={"CXX_SOURCES":"sleep.cpp"}) - host_process = self.spawnSubprocess(self.getBuildArtifact("a.out")) + host_process = self.spawnSubprocess(self.getTestExecutable()) # Create a fake remote process with the same PID as host_process class MyResponder(MockGDBServerResponder): Index: lldb/test/API/functionalities/inferior-assert/TestInferiorAssert.py =================================================================== --- lldb/test/API/functionalities/inferior-assert/TestInferiorAssert.py +++ lldb/test/API/functionalities/inferior-assert/TestInferiorAssert.py @@ -126,7 +126,7 @@ def inferior_asserting(self): """Inferior asserts upon launching; lldb should catch the event and stop.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) self.runCmd("run", RUN_SUCCEEDED) @@ -144,7 +144,7 @@ def inferior_asserting_python(self): """Inferior asserts upon launching; lldb should catch the event and stop.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) @@ -168,7 +168,7 @@ def inferior_asserting_registers(self): """Test that lldb can read registers after asserting.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) self.runCmd("run", RUN_SUCCEEDED) @@ -184,7 +184,7 @@ def inferior_asserting_disassemble(self): """Test that lldb can disassemble frames after asserting.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) @@ -254,7 +254,7 @@ def inferior_asserting_expr(self): """Test that the lldb expression interpreter can read symbols after asserting.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) @@ -278,7 +278,7 @@ def inferior_asserting_step(self): """Test that lldb functions correctly after stepping through a call to assert().""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) Index: lldb/test/API/functionalities/inferior-changed/TestInferiorChanged.py =================================================================== --- lldb/test/API/functionalities/inferior-changed/TestInferiorChanged.py +++ lldb/test/API/functionalities/inferior-changed/TestInferiorChanged.py @@ -39,7 +39,7 @@ def inferior_crashing(self): """Inferior crashes upon launching; lldb should catch the event and stop.""" - self.exe = self.getBuildArtifact("a.out") + self.exe = self.getTestExecutable() self.runCmd("file " + self.exe, CURRENT_EXECUTABLE_SET) self.runCmd("run", RUN_SUCCEEDED) Index: lldb/test/API/functionalities/inferior-crashing/TestInferiorCrashing.py =================================================================== --- lldb/test/API/functionalities/inferior-crashing/TestInferiorCrashing.py +++ lldb/test/API/functionalities/inferior-crashing/TestInferiorCrashing.py @@ -58,7 +58,7 @@ def inferior_crashing(self): """Inferior crashes upon launching; lldb should catch the event and stop.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) self.runCmd("run", RUN_SUCCEEDED) @@ -80,7 +80,7 @@ def inferior_crashing_python(self): """Inferior crashes upon launching; lldb should catch the event and stop.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) @@ -106,7 +106,7 @@ def inferior_crashing_registers(self): """Test that lldb can read registers after crashing.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) self.runCmd("run", RUN_SUCCEEDED) @@ -118,7 +118,7 @@ def inferior_crashing_expr(self): """Test that the lldb expression interpreter can read symbols after crashing.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) self.runCmd("run", RUN_SUCCEEDED) Index: lldb/test/API/functionalities/inferior-crashing/TestInferiorCrashingStep.py =================================================================== --- lldb/test/API/functionalities/inferior-crashing/TestInferiorCrashingStep.py +++ lldb/test/API/functionalities/inferior-crashing/TestInferiorCrashingStep.py @@ -79,7 +79,7 @@ def inferior_crashing(self): """Inferior crashes upon launching; lldb should catch the event and stop.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) self.runCmd("run", RUN_SUCCEEDED) @@ -102,7 +102,7 @@ def inferior_crashing_python(self): """Inferior crashes upon launching; lldb should catch the event and stop.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) @@ -127,7 +127,7 @@ def inferior_crashing_registers(self): """Test that lldb can read registers after crashing.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) self.runCmd("run", RUN_SUCCEEDED) @@ -139,7 +139,7 @@ def inferior_crashing_expr(self): """Test that the lldb expression interpreter can read symbols after crashing.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) self.runCmd("run", RUN_SUCCEEDED) @@ -153,7 +153,7 @@ def inferior_crashing_step(self): """Test that lldb functions correctly after stepping through a crash.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) self.set_breakpoint(self.line) @@ -182,7 +182,7 @@ @expectedFailureNetBSD def inferior_crashing_step_after_break(self): """Test that lldb behaves correctly when stepping after a crash.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) self.runCmd("run", RUN_SUCCEEDED) @@ -206,7 +206,7 @@ def inferior_crashing_expr_step_expr(self): """Test that lldb expressions work before and after stepping after a crash.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) self.runCmd("run", RUN_SUCCEEDED) Index: lldb/test/API/functionalities/inferior-crashing/recursive-inferior/TestRecursiveInferior.py =================================================================== --- lldb/test/API/functionalities/inferior-crashing/recursive-inferior/TestRecursiveInferior.py +++ lldb/test/API/functionalities/inferior-crashing/recursive-inferior/TestRecursiveInferior.py @@ -55,7 +55,7 @@ def recursive_inferior_crashing(self): """Inferior crashes upon launching; lldb should catch the event and stop.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) self.runCmd("run", RUN_SUCCEEDED) @@ -90,7 +90,7 @@ def recursive_inferior_crashing_python(self): """Inferior crashes upon launching; lldb should catch the event and stop.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) @@ -116,7 +116,7 @@ def recursive_inferior_crashing_registers(self): """Test that lldb can read registers after crashing.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) self.runCmd("run", RUN_SUCCEEDED) @@ -128,7 +128,7 @@ def recursive_inferior_crashing_expr(self): """Test that the lldb expression interpreter can read symbols after crashing.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) self.runCmd("run", RUN_SUCCEEDED) Index: lldb/test/API/functionalities/inferior-crashing/recursive-inferior/TestRecursiveInferiorStep.py =================================================================== --- lldb/test/API/functionalities/inferior-crashing/recursive-inferior/TestRecursiveInferiorStep.py +++ lldb/test/API/functionalities/inferior-crashing/recursive-inferior/TestRecursiveInferiorStep.py @@ -54,7 +54,7 @@ def recursive_inferior_crashing_step(self): """Test that lldb functions correctly after stepping through a crash.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) self.set_breakpoint(self.line) @@ -81,7 +81,7 @@ def recursive_inferior_crashing_step_after_break(self): """Test that lldb behaves correctly when stepping after a crash.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) self.runCmd("run", RUN_SUCCEEDED) @@ -105,7 +105,7 @@ def recursive_inferior_crashing_expr_step_expr(self): """Test that lldb expressions work before and after stepping after a crash.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) self.runCmd("run", RUN_SUCCEEDED) Index: lldb/test/API/functionalities/inline-stepping/TestInlineStepping.py =================================================================== --- lldb/test/API/functionalities/inline-stepping/TestInlineStepping.py +++ lldb/test/API/functionalities/inline-stepping/TestInlineStepping.py @@ -142,7 +142,7 @@ def inline_stepping(self): """Use Python APIs to test stepping over and hitting breakpoints.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) @@ -254,7 +254,7 @@ def inline_stepping_step_over(self): """Use Python APIs to test stepping over and hitting breakpoints.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) @@ -285,7 +285,7 @@ def step_in_template(self): """Use Python APIs to test stepping in to templated functions.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/functionalities/jitloader_gdb/TestJITLoaderGDB.py =================================================================== --- lldb/test/API/functionalities/jitloader_gdb/TestJITLoaderGDB.py +++ lldb/test/API/functionalities/jitloader_gdb/TestJITLoaderGDB.py @@ -20,7 +20,7 @@ def test_bogus_values(self): """Test that we handle inferior misusing the GDB JIT interface""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) Index: lldb/test/API/functionalities/limit-debug-info/TestLimitDebugInfo.py =================================================================== --- lldb/test/API/functionalities/limit-debug-info/TestLimitDebugInfo.py +++ lldb/test/API/functionalities/limit-debug-info/TestLimitDebugInfo.py @@ -37,7 +37,7 @@ @skipIf(compiler="clang", compiler_version=['<', '7.0']) def test_one_and_two_debug(self): self.build() - target = self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + target = self.dbg.CreateTarget(self.getTestExecutable()) self._check_debug_info_is_limited(target) @@ -76,7 +76,7 @@ @skipIf(compiler="clang", compiler_version=['<', '7.0']) def test_two_debug(self): self.build(dictionary=dict(STRIP_ONE="1")) - target = self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + target = self.dbg.CreateTarget(self.getTestExecutable()) self._check_debug_info_is_limited(target) @@ -119,7 +119,7 @@ @skipIf(compiler="clang", compiler_version=['<', '7.0']) def test_one_debug(self): self.build(dictionary=dict(STRIP_TWO="1")) - target = self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + target = self.dbg.CreateTarget(self.getTestExecutable()) self._check_debug_info_is_limited(target) Index: lldb/test/API/functionalities/load_after_attach/TestLoadAfterAttach.py =================================================================== --- lldb/test/API/functionalities/load_after_attach/TestLoadAfterAttach.py +++ lldb/test/API/functionalities/load_after_attach/TestLoadAfterAttach.py @@ -15,7 +15,7 @@ ctx = self.platformContext lib_name = ctx.shlib_prefix + 'lib_b.' + ctx.shlib_extension - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() lib = self.getBuildArtifact(lib_name) target = self.dbg.CreateTarget(exe) Index: lldb/test/API/functionalities/load_unload/TestLoadUnload.py =================================================================== --- lldb/test/API/functionalities/load_unload/TestLoadUnload.py +++ lldb/test/API/functionalities/load_unload/TestLoadUnload.py @@ -105,7 +105,7 @@ old_dylib = os.path.join(self.getBuildDir(), dylibName) new_dylib = os.path.join(new_dir, dylibName) - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) self.expect("target modules list", @@ -152,7 +152,7 @@ """Test (DY)LD_LIBRARY_PATH after moving libd.dylib, which defines d_function, somewhere else.""" self.copy_shlibs_to_remote(hidden_dir=True) - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Shut off ANSI color usage so we don't get ANSI escape sequences @@ -220,7 +220,7 @@ """Test that lldb process load/unload command work correctly.""" self.copy_shlibs_to_remote() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Break at main.cpp before the call to dlopen(). @@ -309,7 +309,7 @@ """Test breakpoint by name works correctly with dlopen'ing.""" self.copy_shlibs_to_remote() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Break by function name a_function (not yet loaded). @@ -353,7 +353,7 @@ """Test stepping over code that loads a shared library works correctly.""" self.copy_shlibs_to_remote() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Break by function name a_function (not yet loaded). @@ -383,7 +383,7 @@ """Test that we can set breakpoints correctly in static initializers""" self.copy_shlibs_to_remote() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) a_init_bp_num = lldbutil.run_break_set_by_symbol( Index: lldb/test/API/functionalities/location-list-lookup/TestLocationListLookup.py =================================================================== --- lldb/test/API/functionalities/location-list-lookup/TestLocationListLookup.py +++ lldb/test/API/functionalities/location-list-lookup/TestLocationListLookup.py @@ -17,7 +17,7 @@ @skipIf(oslist=["linux"], archs=["arm"]) def test_loclist(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) Index: lldb/test/API/functionalities/longjmp/TestLongjmp.py =================================================================== --- lldb/test/API/functionalities/longjmp/TestLongjmp.py +++ lldb/test/API/functionalities/longjmp/TestLongjmp.py @@ -42,7 +42,7 @@ self.step_back_out() def start_test(self, symbol): - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) Index: lldb/test/API/functionalities/memory-region/TestMemoryRegion.py =================================================================== --- lldb/test/API/functionalities/memory-region/TestMemoryRegion.py +++ lldb/test/API/functionalities/memory-region/TestMemoryRegion.py @@ -33,7 +33,7 @@ self.build() # Set breakpoint in main and run - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=-1, loc_exact=True) Index: lldb/test/API/functionalities/memory/cache/TestMemoryCache.py =================================================================== --- lldb/test/API/functionalities/memory/cache/TestMemoryCache.py +++ lldb/test/API/functionalities/memory/cache/TestMemoryCache.py @@ -24,7 +24,7 @@ def test_memory_cache(self): """Test the MemoryCache class with a sequence of 'memory read' and 'memory write' operations.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Break in main() after the variables are assigned values. Index: lldb/test/API/functionalities/memory/find/TestMemoryFind.py =================================================================== --- lldb/test/API/functionalities/memory/find/TestMemoryFind.py +++ lldb/test/API/functionalities/memory/find/TestMemoryFind.py @@ -23,7 +23,7 @@ def test_memory_find(self): """Test the 'memory find' command.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Break in main() after the variables are assigned values. Index: lldb/test/API/functionalities/memory/tag/TestMemoryTag.py =================================================================== --- lldb/test/API/functionalities/memory/tag/TestMemoryTag.py +++ lldb/test/API/functionalities/memory/tag/TestMemoryTag.py @@ -22,7 +22,7 @@ self.skipTest("Requires a target without AArch64 MTE.") self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line(self, "main.cpp", Index: lldb/test/API/functionalities/module_cache/bsd/TestModuleCacheBSD.py =================================================================== --- lldb/test/API/functionalities/module_cache/bsd/TestModuleCacheBSD.py +++ lldb/test/API/functionalities/module_cache/bsd/TestModuleCacheBSD.py @@ -77,7 +77,7 @@ This test only works on darwin because of the way DWARF is stored where the debug map will refer to .o files inside of .a files. """ - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a module with no depedencies. target = self.createTestTarget(load_dependent_modules=False) Index: lldb/test/API/functionalities/module_cache/simple_exe/TestModuleCacheSimple.py =================================================================== --- lldb/test/API/functionalities/module_cache/simple_exe/TestModuleCacheSimple.py +++ lldb/test/API/functionalities/module_cache/simple_exe/TestModuleCacheSimple.py @@ -44,7 +44,7 @@ target and should cause the cache to get updated so the cache file should get an updated modification time. """ - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a module with no depedencies. target = self.createTestTarget(load_dependent_modules=False) Index: lldb/test/API/functionalities/mtc/simple/TestMTCSimple.py =================================================================== --- lldb/test/API/functionalities/mtc/simple/TestMTCSimple.py +++ lldb/test/API/functionalities/mtc/simple/TestMTCSimple.py @@ -30,7 +30,7 @@ self.assertNotEqual(self.mtc_dylib_path, "") # Load the test - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.expect("file " + exe, patterns=["Current executable set to .*a.out"]) self.runCmd("env DYLD_INSERT_LIBRARIES=%s" % self.mtc_dylib_path) Index: lldb/test/API/functionalities/non-overlapping-index-variable-i/TestIndexVariable.py =================================================================== --- lldb/test/API/functionalities/non-overlapping-index-variable-i/TestIndexVariable.py +++ lldb/test/API/functionalities/non-overlapping-index-variable-i/TestIndexVariable.py @@ -22,7 +22,7 @@ def test_eval_index_variable(self): """Test expressions of variable 'i' which appears in two for loops.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( Index: lldb/test/API/functionalities/plugins/python_os_plugin/TestPythonOSPlugin.py =================================================================== --- lldb/test/API/functionalities/plugins/python_os_plugin/TestPythonOSPlugin.py +++ lldb/test/API/functionalities/plugins/python_os_plugin/TestPythonOSPlugin.py @@ -42,7 +42,7 @@ self.dbg.SetAsync(False) # Create a target by the debugger. - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() python_os_plugin_path = os.path.join(self.getSourceDir(), "operating_system.py") target = self.dbg.CreateTarget(exe) @@ -126,7 +126,7 @@ self.dbg.SetAsync(False) # Create a target by the debugger. - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() python_os_plugin_path = os.path.join(self.getSourceDir(), "operating_system2.py") target = self.dbg.CreateTarget(exe) Index: lldb/test/API/functionalities/postmortem/minidump/TestMiniDump.py =================================================================== --- lldb/test/API/functionalities/postmortem/minidump/TestMiniDump.py +++ lldb/test/API/functionalities/postmortem/minidump/TestMiniDump.py @@ -112,7 +112,7 @@ def test_deeper_stack_in_mini_dump(self): """Test that we can examine a more interesting stack in a mini dump.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() core = self.getBuildArtifact("core.dmp") try: # Set a breakpoint and capture a mini dump. @@ -148,7 +148,7 @@ def test_local_variables_in_mini_dump(self): """Test that we can examine local variables in a mini dump.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() core = self.getBuildArtifact("core.dmp") try: # Set a breakpoint and capture a mini dump. Index: lldb/test/API/functionalities/pre_run_dylibs/TestPreRunDylibs.py =================================================================== --- lldb/test/API/functionalities/pre_run_dylibs/TestPreRunDylibs.py +++ lldb/test/API/functionalities/pre_run_dylibs/TestPreRunDylibs.py @@ -15,7 +15,7 @@ """Test that we find directly linked dylib pre-run.""" self.build() - target = self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + target = self.dbg.CreateTarget(self.getTestExecutable()) self.assertTrue(target, VALID_TARGET) # I don't know what the name of a shared library Index: lldb/test/API/functionalities/process_crash_info/TestProcessCrashInfo.py =================================================================== --- lldb/test/API/functionalities/process_crash_info/TestProcessCrashInfo.py +++ lldb/test/API/functionalities/process_crash_info/TestProcessCrashInfo.py @@ -31,7 +31,7 @@ """Test that `process status --verbose` fetches the extended crash information dictionary from the command-line properly.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.expect("file " + exe, patterns=["Current executable set to .*a.out"]) @@ -48,7 +48,7 @@ """Test that lldb can fetch a crashed process' extended crash information dictionary from the api properly.""" self.build() - target = self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + target = self.dbg.CreateTarget(self.getTestExecutable()) self.assertTrue(target, VALID_TARGET) target.LaunchSimple(None, None, os.getcwd()) Index: lldb/test/API/functionalities/process_group/TestChangeProcessGroup.py =================================================================== --- lldb/test/API/functionalities/process_group/TestChangeProcessGroup.py +++ lldb/test/API/functionalities/process_group/TestChangeProcessGroup.py @@ -28,7 +28,7 @@ @skipIfwatchOS # fork not available on watchOS. def test_setpgid(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Use a file as a synchronization point between test and inferior. pid_file_path = lldbutil.append_to_process_working_directory(self, Index: lldb/test/API/functionalities/process_save_core/TestProcessSaveCore.py =================================================================== --- lldb/test/API/functionalities/process_save_core/TestProcessSaveCore.py +++ lldb/test/API/functionalities/process_save_core/TestProcessSaveCore.py @@ -19,7 +19,7 @@ def test_cannot_save_core_unless_process_stopped(self): """Test that SaveCore fails if the process isn't stopped.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() core = self.getBuildArtifact("core.dmp") target = self.dbg.CreateTarget(exe) process = target.LaunchSimple( @@ -33,7 +33,7 @@ def test_save_windows_mini_dump(self): """Test that we can save a Windows mini dump.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() core = self.getBuildArtifact("core.dmp") try: target = self.dbg.CreateTarget(exe) @@ -67,7 +67,7 @@ @skipUnlessPlatform(["freebsd", "netbsd"]) def test_save_core_via_process_plugin(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() core = self.getBuildArtifact("a.out.core") try: target = self.dbg.CreateTarget(exe) Index: lldb/test/API/functionalities/process_save_core_minidump/TestProcessSaveCoreMinidump.py =================================================================== --- lldb/test/API/functionalities/process_save_core_minidump/TestProcessSaveCoreMinidump.py +++ lldb/test/API/functionalities/process_save_core_minidump/TestProcessSaveCoreMinidump.py @@ -19,7 +19,7 @@ def test_save_linux_mini_dump(self): """Test that we can save a Linux mini dump.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() core = self.getBuildArtifact("core.dmp") try: target = self.dbg.CreateTarget(exe) Index: lldb/test/API/functionalities/progress_reporting/TestTrimmedProgressReporting.py =================================================================== --- lldb/test/API/functionalities/progress_reporting/TestTrimmedProgressReporting.py +++ lldb/test/API/functionalities/progress_reporting/TestTrimmedProgressReporting.py @@ -25,7 +25,7 @@ self.expect("set set term-width " + str(term_width)) self.expect("set show term-width", substrs=["term-width (int) = " + str(term_width)]) - self.child.send("file " + self.getBuildArtifact("a.out") + "\n") + self.child.send("file " + self.getTestExecutable() + "\n") self.child.expect(pattern_list) Index: lldb/test/API/functionalities/ptr_refs/TestPtrRefs.py =================================================================== --- lldb/test/API/functionalities/ptr_refs/TestPtrRefs.py +++ lldb/test/API/functionalities/ptr_refs/TestPtrRefs.py @@ -18,7 +18,7 @@ def test_ptr_refs(self): """Test format string functionality.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/functionalities/recursion/TestValueObjectRecursion.py =================================================================== --- lldb/test/API/functionalities/recursion/TestValueObjectRecursion.py +++ lldb/test/API/functionalities/recursion/TestValueObjectRecursion.py @@ -25,7 +25,7 @@ def test_with_run_command(self): """Test that deeply nested ValueObjects still work.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/rerun/TestRerun.py =================================================================== --- lldb/test/API/functionalities/rerun/TestRerun.py +++ lldb/test/API/functionalities/rerun/TestRerun.py @@ -15,7 +15,7 @@ def test(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("target create %s" % exe) Index: lldb/test/API/functionalities/return-value/TestReturnValue.py =================================================================== --- lldb/test/API/functionalities/return-value/TestReturnValue.py +++ lldb/test/API/functionalities/return-value/TestReturnValue.py @@ -50,7 +50,7 @@ def test_with_python(self): """Test getting return values from stepping out.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() (self.target, self.process, thread, inner_sint_bkpt) = lldbutil.run_to_name_breakpoint(self, "inner_sint", exe_name = exe) error = lldb.SBError() @@ -178,7 +178,7 @@ @expectedFailureAll(oslist=["windows"], archs=["i[3-6]86", "x86_64"], bugnumber="llvm.org/pr24778") def test_vector_values(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() error = lldb.SBError() self.target = self.dbg.CreateTarget(exe) @@ -205,7 +205,7 @@ @expectedFailureAll(oslist=["windows"], bugnumber="llvm.org/pr24778") def test_for_cpp_support(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() (self.target, self.process, thread, inner_sint_bkpt) = lldbutil.run_to_name_breakpoint(self, "inner_sint", exe_name = exe) error = lldb.SBError() Index: lldb/test/API/functionalities/scripted_process/TestScriptedProcess.py =================================================================== --- lldb/test/API/functionalities/scripted_process/TestScriptedProcess.py +++ lldb/test/API/functionalities/scripted_process/TestScriptedProcess.py @@ -67,7 +67,7 @@ self.runCmd("settings set target.load-script-from-symbol-file true") self.move_blueprint_to_dsym('invalid_scripted_process.py') - target = self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + target = self.dbg.CreateTarget(self.getTestExecutable()) self.assertTrue(target, VALID_TARGET) log_file = self.getBuildArtifact('thread.log') self.runCmd("log enable lldb thread -f " + log_file) @@ -97,7 +97,7 @@ id, name stop reason and register context. """ self.build() - target = self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + target = self.dbg.CreateTarget(self.getTestExecutable()) self.assertTrue(target, VALID_TARGET) os.environ['SKIP_SCRIPTED_PROCESS_LAUNCH'] = '1' Index: lldb/test/API/functionalities/scripted_process/TestStackCoreScriptedProcess.py =================================================================== --- lldb/test/API/functionalities/scripted_process/TestStackCoreScriptedProcess.py +++ lldb/test/API/functionalities/scripted_process/TestStackCoreScriptedProcess.py @@ -45,7 +45,7 @@ """Test that we can launch an lldb scripted process from the command line, check its process ID and read string from memory.""" self.build() - target = self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + target = self.dbg.CreateTarget(self.getTestExecutable()) self.assertTrue(target, VALID_TARGET) main_module = self.get_module_with_name(target, 'a.out') Index: lldb/test/API/functionalities/set-data/TestSetData.py =================================================================== --- lldb/test/API/functionalities/set-data/TestSetData.py +++ lldb/test/API/functionalities/set-data/TestSetData.py @@ -18,7 +18,7 @@ def test_set_data(self): """Test setting the contents of variables and registers using raw data.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) self.runCmd("br s -p First") Index: lldb/test/API/functionalities/signal/TestSendSignal.py =================================================================== --- lldb/test/API/functionalities/signal/TestSendSignal.py +++ lldb/test/API/functionalities/signal/TestSendSignal.py @@ -23,7 +23,7 @@ def test_with_run_command(self): """Test that lldb command 'process signal SIGUSR1' sends a signal to the inferior process.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) Index: lldb/test/API/functionalities/signal/handle-abrt/TestHandleAbort.py =================================================================== --- lldb/test/API/functionalities/signal/handle-abrt/TestHandleAbort.py +++ lldb/test/API/functionalities/signal/handle-abrt/TestHandleAbort.py @@ -22,7 +22,7 @@ Stopped at a breakpoint in the handler, verify that the backtrace includes the function that called abort().""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) Index: lldb/test/API/functionalities/signal/handle-segv/TestHandleSegv.py =================================================================== --- lldb/test/API/functionalities/signal/handle-segv/TestHandleSegv.py +++ lldb/test/API/functionalities/signal/handle-segv/TestHandleSegv.py @@ -18,7 +18,7 @@ @expectedFailureNetBSD def test_inferior_handle_sigsegv(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) Index: lldb/test/API/functionalities/signal/raise/TestRaise.py =================================================================== --- lldb/test/API/functionalities/signal/raise/TestRaise.py +++ lldb/test/API/functionalities/signal/raise/TestRaise.py @@ -62,7 +62,7 @@ def signal_test(self, signal, test_passing): """Test that we handle inferior raising signals""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) Index: lldb/test/API/functionalities/stats_api/TestStatisticsAPI.py =================================================================== --- lldb/test/API/functionalities/stats_api/TestStatisticsAPI.py +++ lldb/test/API/functionalities/stats_api/TestStatisticsAPI.py @@ -14,7 +14,7 @@ def test_stats_api(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) # Test enabling/disabling stats Index: lldb/test/API/functionalities/step-avoids-no-debug/TestStepNoDebug.py =================================================================== --- lldb/test/API/functionalities/step-avoids-no-debug/TestStepNoDebug.py +++ lldb/test/API/functionalities/step-avoids-no-debug/TestStepNoDebug.py @@ -89,7 +89,7 @@ (name, pattern)) def get_to_starting_point(self): - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() error = lldb.SBError() self.target = self.dbg.CreateTarget(exe) Index: lldb/test/API/functionalities/tail_call_frames/cross_dso/TestCrossDSOTailCalls.py =================================================================== --- lldb/test/API/functionalities/tail_call_frames/cross_dso/TestCrossDSOTailCalls.py +++ lldb/test/API/functionalities/tail_call_frames/cross_dso/TestCrossDSOTailCalls.py @@ -21,7 +21,7 @@ @expectedFailureAll(archs=['arm', 'aarch64'], bugnumber="llvm.org/PR44561") def test_cross_dso_tail_calls(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/functionalities/tail_call_frames/cross_object/TestCrossObjectTailCalls.py =================================================================== --- lldb/test/API/functionalities/tail_call_frames/cross_object/TestCrossObjectTailCalls.py +++ lldb/test/API/functionalities/tail_call_frames/cross_object/TestCrossObjectTailCalls.py @@ -21,7 +21,7 @@ @expectedFailureAll(archs=['arm', 'aarch64'], bugnumber="llvm.org/PR44561") def test_cross_object_tail_calls(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/functionalities/tail_call_frames/sbapi_support/TestTailCallFrameSBAPI.py =================================================================== --- lldb/test/API/functionalities/tail_call_frames/sbapi_support/TestTailCallFrameSBAPI.py +++ lldb/test/API/functionalities/tail_call_frames/sbapi_support/TestTailCallFrameSBAPI.py @@ -18,7 +18,7 @@ self.do_test() def do_test(self): - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) Index: lldb/test/API/functionalities/tail_call_frames/thread_step_out_or_return/TestSteppingOutWithArtificialFrames.py =================================================================== --- lldb/test/API/functionalities/tail_call_frames/thread_step_out_or_return/TestSteppingOutWithArtificialFrames.py +++ lldb/test/API/functionalities/tail_call_frames/thread_step_out_or_return/TestSteppingOutWithArtificialFrames.py @@ -16,7 +16,7 @@ NO_DEBUG_INFO_TESTCASE = True def prepare_thread(self): - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) Index: lldb/test/API/functionalities/target-new-solib-notifications/TestModuleLoadedNotifys.py =================================================================== --- lldb/test/API/functionalities/target-new-solib-notifications/TestModuleLoadedNotifys.py +++ lldb/test/API/functionalities/target-new-solib-notifications/TestModuleLoadedNotifys.py @@ -30,7 +30,7 @@ def test_launch_notifications(self): """Test that lldb broadcasts newly loaded libraries in batches.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.dbg.SetAsync(False) listener = self.dbg.GetListener() Index: lldb/test/API/functionalities/thread/break_after_join/TestBreakAfterJoin.py =================================================================== --- lldb/test/API/functionalities/thread/break_after_join/TestBreakAfterJoin.py +++ lldb/test/API/functionalities/thread/break_after_join/TestBreakAfterJoin.py @@ -34,7 +34,7 @@ """Test breakpoint handling after a thread join.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # This should create a breakpoint in the main thread. Index: lldb/test/API/functionalities/thread/concurrent_events/exit/TestConcurrentThreadExit.py =================================================================== --- lldb/test/API/functionalities/thread/concurrent_events/exit/TestConcurrentThreadExit.py +++ lldb/test/API/functionalities/thread/concurrent_events/exit/TestConcurrentThreadExit.py @@ -17,6 +17,6 @@ @skipIf(oslist=no_match(["linux"])) def test(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) self.expect("run", substrs=["exited with status = 47"]) Index: lldb/test/API/functionalities/thread/crash_during_step/TestCrashDuringStep.py =================================================================== --- lldb/test/API/functionalities/thread/crash_during_step/TestCrashDuringStep.py +++ lldb/test/API/functionalities/thread/crash_during_step/TestCrashDuringStep.py @@ -24,7 +24,7 @@ def test_step_inst_with(self): """Test thread creation during step-inst handling.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target and target.IsValid(), "Target is valid") Index: lldb/test/API/functionalities/thread/create_after_attach/TestCreateAfterAttach.py =================================================================== --- lldb/test/API/functionalities/thread/create_after_attach/TestCreateAfterAttach.py +++ lldb/test/API/functionalities/thread/create_after_attach/TestCreateAfterAttach.py @@ -29,7 +29,7 @@ def test_create_after_attach(self): """Test thread creation after process attach.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Spawn a new process # use realpath to workaround llvm.org/pr48376 Index: lldb/test/API/functionalities/thread/create_during_step/TestCreateDuringStep.py =================================================================== --- lldb/test/API/functionalities/thread/create_during_step/TestCreateDuringStep.py +++ lldb/test/API/functionalities/thread/create_during_step/TestCreateDuringStep.py @@ -83,7 +83,7 @@ def create_during_step_base(self, step_cmd, step_stop_reason): """Test thread creation while using step-in.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Get the target process Index: lldb/test/API/functionalities/thread/exit_during_break/TestExitDuringBreak.py =================================================================== --- lldb/test/API/functionalities/thread/exit_during_break/TestExitDuringBreak.py +++ lldb/test/API/functionalities/thread/exit_during_break/TestExitDuringBreak.py @@ -23,7 +23,7 @@ def test(self): """Test thread exit during breakpoint handling.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # This should create a breakpoint in the main thread. Index: lldb/test/API/functionalities/thread/exit_during_step/TestExitDuringStep.py =================================================================== --- lldb/test/API/functionalities/thread/exit_during_step/TestExitDuringStep.py +++ lldb/test/API/functionalities/thread/exit_during_step/TestExitDuringStep.py @@ -50,7 +50,7 @@ def exit_during_step_base(self, step_cmd, step_stop_reason, by_instruction): """Test thread exit during step handling.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # This should create a breakpoint in the main thread. Index: lldb/test/API/functionalities/thread/jump/TestThreadJump.py =================================================================== --- lldb/test/API/functionalities/thread/jump/TestThreadJump.py +++ lldb/test/API/functionalities/thread/jump/TestThreadJump.py @@ -17,7 +17,7 @@ def test(self): """Test thread jump handling.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Find the line numbers for our breakpoints. Index: lldb/test/API/functionalities/thread/multi_break/TestMultipleBreakpoints.py =================================================================== --- lldb/test/API/functionalities/thread/multi_break/TestMultipleBreakpoints.py +++ lldb/test/API/functionalities/thread/multi_break/TestMultipleBreakpoints.py @@ -34,7 +34,7 @@ def test(self): """Test simultaneous breakpoints in multiple threads.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # This should create a breakpoint in the main thread. Index: lldb/test/API/functionalities/thread/num_threads/TestNumThreads.py =================================================================== --- lldb/test/API/functionalities/thread/num_threads/TestNumThreads.py +++ lldb/test/API/functionalities/thread/num_threads/TestNumThreads.py @@ -25,7 +25,7 @@ def test_number_of_threads(self): """Test number of threads.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # This should create a breakpoint with 1 location. @@ -65,7 +65,7 @@ def test_unique_stacks(self): """Test backtrace unique with multiple threads executing the same stack.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Set a break point on the thread3 notify all (should get hit on threads 4-13). Index: lldb/test/API/functionalities/thread/state/TestThreadStates.py =================================================================== --- lldb/test/API/functionalities/thread/state/TestThreadStates.py +++ lldb/test/API/functionalities/thread/state/TestThreadStates.py @@ -70,7 +70,7 @@ def thread_state_after_breakpoint_test(self): """Test thread state after breakpoint.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # This should create a breakpoint in the main thread. @@ -110,7 +110,7 @@ def thread_state_after_continue_test(self): """Test thread state after continue.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # This should create a breakpoint in the main thread. @@ -152,7 +152,7 @@ def thread_state_after_expression_test(self): """Test thread state after expression.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # This should create a breakpoint in the main thread. @@ -194,7 +194,7 @@ def test_process_interrupt(self): """Test process interrupt and continue.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # This should create a breakpoint in the main thread. @@ -238,7 +238,7 @@ def thread_states_test(self): """Test thread states (comprehensive).""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # This should create a breakpoint in the main thread. Index: lldb/test/API/functionalities/thread/step_until/TestStepUntil.py =================================================================== --- lldb/test/API/functionalities/thread/step_until/TestStepUntil.py +++ lldb/test/API/functionalities/thread/step_until/TestStepUntil.py @@ -23,7 +23,7 @@ def do_until (self, args, until_lines, expected_linenum): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/functionalities/thread/thread_exit/TestThreadExit.py =================================================================== --- lldb/test/API/functionalities/thread/thread_exit/TestThreadExit.py +++ lldb/test/API/functionalities/thread/thread_exit/TestThreadExit.py @@ -27,7 +27,7 @@ def test(self): """Test thread exit handling.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # This should create a breakpoint with 1 location. Index: lldb/test/API/functionalities/thread/thread_specific_break_plus_condition/TestThreadSpecificBpPlusCondition.py =================================================================== --- lldb/test/API/functionalities/thread/thread_specific_break_plus_condition/TestThreadSpecificBpPlusCondition.py +++ lldb/test/API/functionalities/thread/thread_specific_break_plus_condition/TestThreadSpecificBpPlusCondition.py @@ -24,7 +24,7 @@ def test_python(self): """Test that we obey thread conditioned breakpoints.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/functionalities/tsan/basic/TestTsanBasic.py =================================================================== --- lldb/test/API/functionalities/tsan/basic/TestTsanBasic.py +++ lldb/test/API/functionalities/tsan/basic/TestTsanBasic.py @@ -33,7 +33,7 @@ self.line_thread2 = line_number('main.c', '// thread2 line') def tsan_tests(self): - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.expect( "file " + exe, patterns=["Current executable set to .*a.out"]) Index: lldb/test/API/functionalities/tsan/cpp_global_location/TestTsanCPPGlobalLocation.py =================================================================== --- lldb/test/API/functionalities/tsan/cpp_global_location/TestTsanCPPGlobalLocation.py +++ lldb/test/API/functionalities/tsan/cpp_global_location/TestTsanCPPGlobalLocation.py @@ -25,7 +25,7 @@ self.tsan_tests() def tsan_tests(self): - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.expect( "file " + exe, patterns=["Current executable set to .*a.out"]) Index: lldb/test/API/functionalities/tsan/global_location/TestTsanGlobalLocation.py =================================================================== --- lldb/test/API/functionalities/tsan/global_location/TestTsanGlobalLocation.py +++ lldb/test/API/functionalities/tsan/global_location/TestTsanGlobalLocation.py @@ -25,7 +25,7 @@ self.tsan_tests() def tsan_tests(self): - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.expect( "file " + exe, patterns=["Current executable set to .*a.out"]) Index: lldb/test/API/functionalities/tsan/multiple/TestTsanMultiple.py =================================================================== --- lldb/test/API/functionalities/tsan/multiple/TestTsanMultiple.py +++ lldb/test/API/functionalities/tsan/multiple/TestTsanMultiple.py @@ -26,7 +26,7 @@ self.tsan_tests() def tsan_tests(self): - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.expect( "file " + exe, patterns=["Current executable set to .*a.out"]) Index: lldb/test/API/functionalities/tsan/thread_leak/TestTsanThreadLeak.py =================================================================== --- lldb/test/API/functionalities/tsan/thread_leak/TestTsanThreadLeak.py +++ lldb/test/API/functionalities/tsan/thread_leak/TestTsanThreadLeak.py @@ -24,7 +24,7 @@ self.tsan_tests() def tsan_tests(self): - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.expect( "file " + exe, patterns=["Current executable set to .*a.out"]) Index: lldb/test/API/functionalities/tsan/thread_numbers/TestTsanThreadNumbers.py =================================================================== --- lldb/test/API/functionalities/tsan/thread_numbers/TestTsanThreadNumbers.py +++ lldb/test/API/functionalities/tsan/thread_numbers/TestTsanThreadNumbers.py @@ -25,7 +25,7 @@ self.tsan_tests() def tsan_tests(self): - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.expect( "file " + exe, patterns=["Current executable set to .*a.out"]) Index: lldb/test/API/functionalities/tty/TestTerminal.py =================================================================== --- lldb/test/API/functionalities/tty/TestTerminal.py +++ lldb/test/API/functionalities/tty/TestTerminal.py @@ -34,7 +34,7 @@ @no_debug_info_test def test_launch_in_terminal(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) launch_info = lldb.SBLaunchInfo(["-lAF", "/tmp/"]) Index: lldb/test/API/functionalities/type_lookup/TestTypeLookup.py =================================================================== --- lldb/test/API/functionalities/type_lookup/TestTypeLookup.py +++ lldb/test/API/functionalities/type_lookup/TestTypeLookup.py @@ -25,7 +25,7 @@ def test_type_lookup(self): """Test type lookup command.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.mm", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/functionalities/ubsan/basic/TestUbsanBasic.py =================================================================== --- lldb/test/API/functionalities/ubsan/basic/TestUbsanBasic.py +++ lldb/test/API/functionalities/ubsan/basic/TestUbsanBasic.py @@ -27,7 +27,7 @@ def ubsan_tests(self): # Load the test - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) self.registerSanitizerLibrariesWithTarget(target) Index: lldb/test/API/functionalities/ubsan/user-expression/TestUbsanUserExpression.py =================================================================== --- lldb/test/API/functionalities/ubsan/user-expression/TestUbsanUserExpression.py +++ lldb/test/API/functionalities/ubsan/user-expression/TestUbsanUserExpression.py @@ -24,7 +24,7 @@ def ubsan_tests(self): # Load the test - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) self.registerSanitizerLibrariesWithTarget(target) Index: lldb/test/API/functionalities/unwind/aarch64_unwind_pac/TestAArch64UnwindPAC.py =================================================================== --- lldb/test/API/functionalities/unwind/aarch64_unwind_pac/TestAArch64UnwindPAC.py +++ lldb/test/API/functionalities/unwind/aarch64_unwind_pac/TestAArch64UnwindPAC.py @@ -22,7 +22,7 @@ self.line = line_number('main.c', '// Frame func_c') - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( Index: lldb/test/API/functionalities/unwind/ehframe/TestEhFrameUnwind.py =================================================================== --- lldb/test/API/functionalities/unwind/ehframe/TestEhFrameUnwind.py +++ lldb/test/API/functionalities/unwind/ehframe/TestEhFrameUnwind.py @@ -20,7 +20,7 @@ self.build() self.setTearDownCleanup() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/functionalities/unwind/noreturn/TestNoreturnUnwind.py =================================================================== --- lldb/test/API/functionalities/unwind/noreturn/TestNoreturnUnwind.py +++ lldb/test/API/functionalities/unwind/noreturn/TestNoreturnUnwind.py @@ -23,7 +23,7 @@ self.build() self.setTearDownCleanup() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/functionalities/unwind/sigtramp/TestSigtrampUnwind.py =================================================================== --- lldb/test/API/functionalities/unwind/sigtramp/TestSigtrampUnwind.py +++ lldb/test/API/functionalities/unwind/sigtramp/TestSigtrampUnwind.py @@ -23,7 +23,7 @@ self.build() self.setTearDownCleanup() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/functionalities/unwind/zeroth_frame/TestZerothFrame.py =================================================================== --- lldb/test/API/functionalities/unwind/zeroth_frame/TestZerothFrame.py +++ lldb/test/API/functionalities/unwind/zeroth_frame/TestZerothFrame.py @@ -41,7 +41,7 @@ self.build() self.setTearDownCleanup() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/functionalities/value_md5_crash/TestValueMD5Crash.py =================================================================== --- lldb/test/API/functionalities/value_md5_crash/TestValueMD5Crash.py +++ lldb/test/API/functionalities/value_md5_crash/TestValueMD5Crash.py @@ -24,7 +24,7 @@ def test_with_run_command(self): """Verify that the hash computing logic for ValueObject's values can't crash us.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/iohandler/completion/TestIOHandlerCompletion.py =================================================================== --- lldb/test/API/iohandler/completion/TestIOHandlerCompletion.py +++ lldb/test/API/iohandler/completion/TestIOHandlerCompletion.py @@ -21,7 +21,7 @@ @skipIf(oslist=["linux"], archs=["arm", "aarch64"]) def test_completion(self): self.build() - self.launch(dimensions=(100,500), executable=self.getBuildArtifact("a.out")) + self.launch(dimensions=(100,500), executable=self.getTestExecutable()) # Start tab completion, go to the next page and then display all with 'a'. self.child.send("\t\ta") Index: lldb/test/API/iohandler/sigint/TestProcessIOHandlerInterrupt.py =================================================================== --- lldb/test/API/iohandler/sigint/TestProcessIOHandlerInterrupt.py +++ lldb/test/API/iohandler/sigint/TestProcessIOHandlerInterrupt.py @@ -17,7 +17,7 @@ @skipIf(oslist=["linux"], archs=["arm", "aarch64"]) def test(self): self.build(dictionary={"CXX_SOURCES":"cat.cpp"}) - self.launch(executable=self.getBuildArtifact("a.out")) + self.launch(executable=self.getTestExecutable()) self.child.sendline("process launch") self.child.expect("Process .* launched") Index: lldb/test/API/iohandler/stdio/TestIOHandlerProcessSTDIO.py =================================================================== --- lldb/test/API/iohandler/stdio/TestIOHandlerProcessSTDIO.py +++ lldb/test/API/iohandler/stdio/TestIOHandlerProcessSTDIO.py @@ -14,7 +14,7 @@ @skipIf(oslist=["linux"], archs=["arm", "aarch64"]) def test(self): self.build() - self.launch(executable=self.getBuildArtifact("a.out")) + self.launch(executable=self.getTestExecutable()) self.child.sendline("run") self.child.send("foo\n") Index: lldb/test/API/lang/c/anonymous/TestAnonymous.py =================================================================== --- lldb/test/API/lang/c/anonymous/TestAnonymous.py +++ lldb/test/API/lang/c/anonymous/TestAnonymous.py @@ -84,7 +84,7 @@ self.dbg.SetAsync(False) # Create a target - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) @@ -146,7 +146,7 @@ self.dbg.SetAsync(False) # Create a target - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/lang/c/array_types/TestArrayTypes.py =================================================================== --- lldb/test/API/lang/c/array_types/TestArrayTypes.py +++ lldb/test/API/lang/c/array_types/TestArrayTypes.py @@ -21,7 +21,7 @@ def test_and_run_command(self): """Test 'frame variable var_name' on some variables with array types.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( @@ -82,7 +82,7 @@ def test_and_python_api(self): """Use Python APIs to inspect variables with array types.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/lang/c/blocks/TestBlocks.py =================================================================== --- lldb/test/API/lang/c/blocks/TestBlocks.py +++ lldb/test/API/lang/c/blocks/TestBlocks.py @@ -24,7 +24,7 @@ def launch_common(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) self.is_started = False Index: lldb/test/API/lang/c/conflicting-symbol/TestConflictingSymbol.py =================================================================== --- lldb/test/API/lang/c/conflicting-symbol/TestConflictingSymbol.py +++ lldb/test/API/lang/c/conflicting-symbol/TestConflictingSymbol.py @@ -21,7 +21,7 @@ @expectedFailureAll(oslist=["windows"], bugnumber="llvm.org/pr24489") def test_conflicting_symbols(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) @@ -90,7 +90,7 @@ @skipIfWindows # This test is "passing" on Windows, but it is a false positive. def test_shadowed(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/lang/c/const_variables/TestConstVariables.py =================================================================== --- lldb/test/API/lang/c/const_variables/TestConstVariables.py +++ lldb/test/API/lang/c/const_variables/TestConstVariables.py @@ -20,7 +20,7 @@ def test_and_run_command(self): """Test interpreted and JITted expressions on constant values.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Break inside the main. Index: lldb/test/API/lang/c/find_struct_type/TestFindStructTypes.py =================================================================== --- lldb/test/API/lang/c/find_struct_type/TestFindStructTypes.py +++ lldb/test/API/lang/c/find_struct_type/TestFindStructTypes.py @@ -25,7 +25,7 @@ def do_test(self): """Make sure FindTypes actually finds 'struct typename' not just 'typename'.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) Index: lldb/test/API/lang/c/forward/TestForwardDeclaration.py =================================================================== --- lldb/test/API/lang/c/forward/TestForwardDeclaration.py +++ lldb/test/API/lang/c/forward/TestForwardDeclaration.py @@ -15,7 +15,7 @@ def do_test(self, dictionary=None): """Display *bar_ptr when stopped on a function with forward declaration of struct bar.""" self.build(dictionary=dictionary) - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Break inside the foo function which takes a bar_ptr argument. Index: lldb/test/API/lang/c/function_types/TestFunctionTypes.py =================================================================== --- lldb/test/API/lang/c/function_types/TestFunctionTypes.py +++ lldb/test/API/lang/c/function_types/TestFunctionTypes.py @@ -67,7 +67,7 @@ startstr='(int) $2 = 12') def runToBreakpoint(self): - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Break inside the main. Index: lldb/test/API/lang/c/global_variables/TestGlobalVariables.py =================================================================== --- lldb/test/API/lang/c/global_variables/TestGlobalVariables.py +++ lldb/test/API/lang/c/global_variables/TestGlobalVariables.py @@ -28,7 +28,7 @@ self.build() # Create a target by the debugger. - target = self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + target = self.dbg.CreateTarget(self.getTestExecutable()) self.assertTrue(target, VALID_TARGET) self.expect("target variable g_ptr", VARIABLES_DISPLAYED_CORRECTLY, @@ -42,7 +42,7 @@ self.build() # Create a target by the debugger. - target = self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + target = self.dbg.CreateTarget(self.getTestExecutable()) self.assertTrue(target, VALID_TARGET) # Break inside the main. Index: lldb/test/API/lang/c/local_variables/TestLocalVariables.py =================================================================== --- lldb/test/API/lang/c/local_variables/TestLocalVariables.py +++ lldb/test/API/lang/c/local_variables/TestLocalVariables.py @@ -30,7 +30,7 @@ self.build() # Create a target by the debugger. - target = self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + target = self.dbg.CreateTarget(self.getTestExecutable()) self.assertTrue(target, VALID_TARGET) # Break inside the main. Index: lldb/test/API/lang/c/modules/TestCModules.py =================================================================== --- lldb/test/API/lang/c/modules/TestCModules.py +++ lldb/test/API/lang/c/modules/TestCModules.py @@ -24,7 +24,7 @@ @expectedFailureNetBSD def test_expr(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Break inside the foo function which takes a bar_ptr argument. Index: lldb/test/API/lang/c/register_variables/TestRegisterVariables.py =================================================================== --- lldb/test/API/lang/c/register_variables/TestRegisterVariables.py +++ lldb/test/API/lang/c/register_variables/TestRegisterVariables.py @@ -32,7 +32,7 @@ register_variables_count = 0 self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Break inside the main. Index: lldb/test/API/lang/c/set_values/TestSetValues.py =================================================================== --- lldb/test/API/lang/c/set_values/TestSetValues.py +++ lldb/test/API/lang/c/set_values/TestSetValues.py @@ -25,7 +25,7 @@ def test(self): """Test settings and readings of program variables.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Set breakpoints on several places to set program variables. Index: lldb/test/API/lang/c/shared_lib/TestSharedLib.py =================================================================== --- lldb/test/API/lang/c/shared_lib/TestSharedLib.py +++ lldb/test/API/lang/c/shared_lib/TestSharedLib.py @@ -70,7 +70,7 @@ self.dbg.SetAsync(False) # Create a target by the debugger. - target = self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + target = self.dbg.CreateTarget(self.getTestExecutable()) self.assertTrue(target, VALID_TARGET) self.runCmd("settings set target.preload-symbols " + str(preload_symbols).lower()) Index: lldb/test/API/lang/c/shared_lib_stripped_symbols/TestSharedLibStrippedSymbols.py =================================================================== --- lldb/test/API/lang/c/shared_lib_stripped_symbols/TestSharedLibStrippedSymbols.py +++ lldb/test/API/lang/c/shared_lib_stripped_symbols/TestSharedLibStrippedSymbols.py @@ -61,7 +61,7 @@ self.dbg.SetAsync(False) # Create a target by the debugger. - target = self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + target = self.dbg.CreateTarget(self.getTestExecutable()) self.assertTrue(target, VALID_TARGET) # Break inside the foo function which takes a bar_ptr argument. Index: lldb/test/API/lang/c/step-target/TestStepTarget.py =================================================================== --- lldb/test/API/lang/c/step-target/TestStepTarget.py +++ lldb/test/API/lang/c/step-target/TestStepTarget.py @@ -21,7 +21,7 @@ @add_test_categories(['pyapi']) def get_to_start(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/lang/c/stepping/TestStepAndBreakpoints.py =================================================================== --- lldb/test/API/lang/c/stepping/TestStepAndBreakpoints.py +++ lldb/test/API/lang/c/stepping/TestStepAndBreakpoints.py @@ -26,7 +26,7 @@ def test_and_python_api(self): """Test stepping over vrs. hitting breakpoints & subsequent stepping in various forms.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/lang/c/stepping/TestThreadStepping.py =================================================================== --- lldb/test/API/lang/c/stepping/TestThreadStepping.py +++ lldb/test/API/lang/c/stepping/TestThreadStepping.py @@ -29,7 +29,7 @@ def test_step_out_with_run_command(self): """Exercise thread step-out and frame select followed by thread step-out.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Create a breakpoint inside function 'c'. Index: lldb/test/API/lang/c/strings/TestCStrings.py =================================================================== --- lldb/test/API/lang/c/strings/TestCStrings.py +++ lldb/test/API/lang/c/strings/TestCStrings.py @@ -14,7 +14,7 @@ def test_with_run_command(self): """Tests that C strings work as expected in expressions""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) line = line_number('main.c', '// breakpoint 1') lldbutil.run_break_set_by_file_and_line( Index: lldb/test/API/lang/c/tls_globals/TestTlsGlobals.py =================================================================== --- lldb/test/API/lang/c/tls_globals/TestTlsGlobals.py +++ lldb/test/API/lang/c/tls_globals/TestTlsGlobals.py @@ -46,7 +46,7 @@ def test(self): """Test thread-local storage.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) if self.platformIsDarwin(): self.registerSharedLibrariesWithTarget(target, ['liba.dylib']) Index: lldb/test/API/lang/c/typedef/Testtypedef.py =================================================================== --- lldb/test/API/lang/c/typedef/Testtypedef.py +++ lldb/test/API/lang/c/typedef/Testtypedef.py @@ -20,7 +20,7 @@ def image_lookup_for_multiple_typedefs(self): """Test 'image lookup -t a' at different scopes and check for correct display.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) typearray = ( "float", Index: lldb/test/API/lang/c/unicode/TestUnicodeSymbols.py =================================================================== --- lldb/test/API/lang/c/unicode/TestUnicodeSymbols.py +++ lldb/test/API/lang/c/unicode/TestUnicodeSymbols.py @@ -13,7 +13,7 @@ def test_union_members(self): self.build() spec = lldb.SBModuleSpec() - spec.SetFileSpec(lldb.SBFileSpec(self.getBuildArtifact("a.out"))) + spec.SetFileSpec(lldb.SBFileSpec(self.getTestExecutable())) module = lldb.SBModule(spec) self.assertTrue(module.IsValid()) mytype = module.FindFirstType("foobár") Index: lldb/test/API/lang/c/unions/TestUnionMembers.py =================================================================== --- lldb/test/API/lang/c/unions/TestUnionMembers.py +++ lldb/test/API/lang/c/unions/TestUnionMembers.py @@ -45,7 +45,7 @@ self.assertTrue(self.src_file_spec.IsValid(), "breakpoint file") # Get the path of the executable - exe_path = self.getBuildArtifact("a.out") + exe_path = self.getTestExecutable() # Load the executable self.target = self.dbg.CreateTarget(exe_path) Index: lldb/test/API/lang/cpp/alignas_base_class/TestAlignAsBaseClass.py =================================================================== --- lldb/test/API/lang/cpp/alignas_base_class/TestAlignAsBaseClass.py +++ lldb/test/API/lang/cpp/alignas_base_class/TestAlignAsBaseClass.py @@ -10,7 +10,7 @@ @no_debug_info_test def test(self): self.build() - self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + self.dbg.CreateTarget(self.getTestExecutable()) # The offset of f2 should be 8 because of `alignas(8)`. self.expect_expr("(intptr_t)&d3g.f2 - (intptr_t)&d3g", result_value="8") Index: lldb/test/API/lang/cpp/breakpoint-commands/TestCPPBreakpointCommands.py =================================================================== --- lldb/test/API/lang/cpp/breakpoint-commands/TestCPPBreakpointCommands.py +++ lldb/test/API/lang/cpp/breakpoint-commands/TestCPPBreakpointCommands.py @@ -32,7 +32,7 @@ """Test a sequence of breakpoint command add, list, and delete.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target from the debugger. Index: lldb/test/API/lang/cpp/char1632_t/TestChar1632T.py =================================================================== --- lldb/test/API/lang/cpp/char1632_t/TestChar1632T.py +++ lldb/test/API/lang/cpp/char1632_t/TestChar1632T.py @@ -29,7 +29,7 @@ def test(self): """Test that the C++11 support for char16_t and char32_t works correctly.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) Index: lldb/test/API/lang/cpp/class-template-non-type-parameter-pack/TestClassTemplateNonTypeParameterPack.py =================================================================== --- lldb/test/API/lang/cpp/class-template-non-type-parameter-pack/TestClassTemplateNonTypeParameterPack.py +++ lldb/test/API/lang/cpp/class-template-non-type-parameter-pack/TestClassTemplateNonTypeParameterPack.py @@ -11,7 +11,7 @@ @no_debug_info_test def test(self): self.build() - self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + self.dbg.CreateTarget(self.getTestExecutable()) self.expect_expr("emptyNonTypePack", result_type="NonTypePack<>", result_children=[ValueCheck(name="a", type="int")]) Index: lldb/test/API/lang/cpp/class-template-type-parameter-pack/TestClassTemplateTypeParameterPack.py =================================================================== --- lldb/test/API/lang/cpp/class-template-type-parameter-pack/TestClassTemplateTypeParameterPack.py +++ lldb/test/API/lang/cpp/class-template-type-parameter-pack/TestClassTemplateTypeParameterPack.py @@ -11,7 +11,7 @@ @no_debug_info_test def test(self): self.build() - self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + self.dbg.CreateTarget(self.getTestExecutable()) self.expect_expr("emptyTypePack", result_type="TypePack<>", result_children=[ValueCheck(name="a", type="int")]) Index: lldb/test/API/lang/cpp/class_static/TestStaticVariables.py =================================================================== --- lldb/test/API/lang/cpp/class_static/TestStaticVariables.py +++ lldb/test/API/lang/cpp/class_static/TestStaticVariables.py @@ -23,7 +23,7 @@ def test_with_run_command(self): """Test that file and class static variables display correctly.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=True) @@ -65,7 +65,7 @@ complete debug information. """ self.build() - target = self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + target = self.dbg.CreateTarget(self.getTestExecutable()) self.assertTrue(target, VALID_TARGET) # Global variables are no longer displayed with the "frame variable" @@ -108,7 +108,7 @@ def test_with_python_api(self): """Test Python APIs on file and class static variables.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/lang/cpp/class_types/TestClassTypes.py =================================================================== --- lldb/test/API/lang/cpp/class_types/TestClassTypes.py +++ lldb/test/API/lang/cpp/class_types/TestClassTypes.py @@ -22,7 +22,7 @@ def test_with_run_command(self): """Test 'frame variable this' when stopped on a class constructor.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Break on the ctor function of class C. @@ -58,7 +58,7 @@ def test_with_python_api(self): """Use Python APIs to create a breakpoint by (filespec, line).""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) @@ -69,7 +69,7 @@ fsDir = os.path.normpath(filespec.GetDirectory()) fsFile = filespec.GetFilename() - self.assertTrue(fsDir == os.path.dirname(self.getBuildArtifact("a.out")) + self.assertTrue(fsDir == os.path.dirname(self.getTestExecutable()) and fsFile == "a.out", "FileSpec matches the executable") @@ -117,7 +117,7 @@ def test_with_expr_parser(self): """Test 'frame variable this' and 'expr this' when stopped inside a constructor.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # rdar://problem/8516141 @@ -173,7 +173,7 @@ def test_with_constructor_name(self): """Test 'frame variable this' and 'expr this' when stopped inside a constructor.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) @@ -184,7 +184,7 @@ fsDir = os.path.normpath(filespec.GetDirectory()) fsFile = filespec.GetFilename() - self.assertTrue(fsDir == os.path.dirname(self.getBuildArtifact("a.out")) + self.assertTrue(fsDir == os.path.dirname(self.getTestExecutable()) and fsFile == "a.out", "FileSpec matches the executable") Index: lldb/test/API/lang/cpp/class_types/TestClassTypesDisassembly.py =================================================================== --- lldb/test/API/lang/cpp/class_types/TestClassTypesDisassembly.py +++ lldb/test/API/lang/cpp/class_types/TestClassTypesDisassembly.py @@ -77,7 +77,7 @@ def breakOnCtor(self): """Setup/run the program so it stops on C's constructor.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Break on the ctor function of class C. Index: lldb/test/API/lang/cpp/dynamic-value/TestDynamicValue.py =================================================================== --- lldb/test/API/lang/cpp/dynamic-value/TestDynamicValue.py +++ lldb/test/API/lang/cpp/dynamic-value/TestDynamicValue.py @@ -33,7 +33,7 @@ def test_get_dynamic_vals(self): """Test fetching C++ dynamic values from pointers & references.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target from the debugger. Index: lldb/test/API/lang/cpp/elaborated-types/TestElaboratedTypes.py =================================================================== --- lldb/test/API/lang/cpp/elaborated-types/TestElaboratedTypes.py +++ lldb/test/API/lang/cpp/elaborated-types/TestElaboratedTypes.py @@ -14,7 +14,7 @@ @no_debug_info_test def test(self): self.build() - self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + self.dbg.CreateTarget(self.getTestExecutable()) # Add a type formatter for 'Struct'. self.expect("type summary add Struct --summary-string '(summary x=${var.x})'") Index: lldb/test/API/lang/cpp/enum_types/TestCPP11EnumTypes.py =================================================================== --- lldb/test/API/lang/cpp/enum_types/TestCPP11EnumTypes.py +++ lldb/test/API/lang/cpp/enum_types/TestCPP11EnumTypes.py @@ -40,7 +40,7 @@ @skipIf(dwarf_version=['<', '4']) def test(self): self.build() - target = self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + target = self.dbg.CreateTarget(self.getTestExecutable()) self.check_enum("uc") self.check_enum("c") self.check_enum("us") Index: lldb/test/API/lang/cpp/exceptions/TestCPPExceptionBreakpoints.py =================================================================== --- lldb/test/API/lang/cpp/exceptions/TestCPPExceptionBreakpoints.py +++ lldb/test/API/lang/cpp/exceptions/TestCPPExceptionBreakpoints.py @@ -27,7 +27,7 @@ def test(self): """Test lldb exception breakpoint command for CPP.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target from the debugger. Index: lldb/test/API/lang/cpp/frame-var-anon-unions/TestFrameVariableAnonymousUnions.py =================================================================== --- lldb/test/API/lang/cpp/frame-var-anon-unions/TestFrameVariableAnonymousUnions.py +++ lldb/test/API/lang/cpp/frame-var-anon-unions/TestFrameVariableAnonymousUnions.py @@ -13,7 +13,7 @@ def test_with_run_command(self): """Tests that frame variable looks into anonymous unions""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) line = line_number('main.cpp', '// break here') lldbutil.run_break_set_by_file_and_line( Index: lldb/test/API/lang/cpp/global_operators/TestCppGlobalOperators.py =================================================================== --- lldb/test/API/lang/cpp/global_operators/TestCppGlobalOperators.py +++ lldb/test/API/lang/cpp/global_operators/TestCppGlobalOperators.py @@ -20,7 +20,7 @@ self.assertTrue(src_file_spec.IsValid(), "Main source file") # Get the path of the executable - exe_path = self.getBuildArtifact("a.out") + exe_path = self.getTestExecutable() # Load the executable target = self.dbg.CreateTarget(exe_path) Index: lldb/test/API/lang/cpp/gmodules/TestWithModuleDebugging.py =================================================================== --- lldb/test/API/lang/cpp/gmodules/TestWithModuleDebugging.py +++ lldb/test/API/lang/cpp/gmodules/TestWithModuleDebugging.py @@ -19,7 +19,7 @@ self.assertTrue(src_file_spec.IsValid(), "breakpoint file") # Get the path of the executable - exe_path = self.getBuildArtifact("a.out") + exe_path = self.getTestExecutable() # Load the executable target = self.dbg.CreateTarget(exe_path) Index: lldb/test/API/lang/cpp/inlines/TestInlines.py =================================================================== --- lldb/test/API/lang/cpp/inlines/TestInlines.py +++ lldb/test/API/lang/cpp/inlines/TestInlines.py @@ -35,7 +35,7 @@ startstr='(int) $0 =') def runToBreakpoint(self): - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Break inside the main. Index: lldb/test/API/lang/cpp/limit-debug-info/TestWithLimitDebugInfo.py =================================================================== --- lldb/test/API/lang/cpp/limit-debug-info/TestWithLimitDebugInfo.py +++ lldb/test/API/lang/cpp/limit-debug-info/TestWithLimitDebugInfo.py @@ -17,7 +17,7 @@ self.assertTrue(src_file_spec.IsValid(), "breakpoint file") # Get the path of the executable - exe_path = self.getBuildArtifact("a.out") + exe_path = self.getTestExecutable() # Load the executable target = self.dbg.CreateTarget(exe_path) Index: lldb/test/API/lang/cpp/member-and-local-vars-with-same-name/TestMembersAndLocalsWithSameName.py =================================================================== --- lldb/test/API/lang/cpp/member-and-local-vars-with-same-name/TestMembersAndLocalsWithSameName.py +++ lldb/test/API/lang/cpp/member-and-local-vars-with-same-name/TestMembersAndLocalsWithSameName.py @@ -237,7 +237,7 @@ self.assertTrue(self.src_file_spec.IsValid(), "breakpoint file") # Get the path of the executable - exe_path = self.getBuildArtifact("a.out") + exe_path = self.getTestExecutable() # Load the executable self.target = self.dbg.CreateTarget(exe_path) Index: lldb/test/API/lang/cpp/namespace/TestNamespace.py =================================================================== --- lldb/test/API/lang/cpp/namespace/TestNamespace.py +++ lldb/test/API/lang/cpp/namespace/TestNamespace.py @@ -28,7 +28,7 @@ "A::func(int)"] # Create a target by the debugger. - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) module_list = lldb.SBFileSpecList() @@ -53,7 +53,7 @@ names = ["func()", "func(int)"] # Create a target by the debugger. - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) module_list = lldb.SBFileSpecList() @@ -78,7 +78,7 @@ names = ["A::func()", "A::func(int)"] # Create a target by the debugger. - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) module_list = lldb.SBFileSpecList() @@ -129,7 +129,7 @@ def test_with_run_command(self): """Test that anonymous and named namespace variables display correctly.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, Index: lldb/test/API/lang/cpp/namespace/TestNamespaceLookup.py =================================================================== --- lldb/test/API/lang/cpp/namespace/TestNamespaceLookup.py +++ lldb/test/API/lang/cpp/namespace/TestNamespaceLookup.py @@ -42,7 +42,7 @@ def test_scope_lookup_with_run_command(self): """Test scope lookup of functions in lldb.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, @@ -143,7 +143,7 @@ def test_function_scope_lookup_with_run_command(self): """Test scope lookup of functions in lldb.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, @@ -181,7 +181,7 @@ def test_file_scope_lookup_with_run_command(self): """Test file scope lookup in lldb.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, @@ -201,7 +201,7 @@ def test_scope_lookup_before_using_with_run_command(self): """Test scope lookup before using in lldb.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, @@ -225,7 +225,7 @@ def test_scope_after_using_directive_lookup_with_run_command(self): """Test scope lookup after using directive in lldb.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, @@ -247,7 +247,7 @@ def test_scope_after_using_declaration_lookup_with_run_command(self): """Test scope lookup after using declaration in lldb.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, @@ -266,7 +266,7 @@ def test_scope_ambiguity_after_using_lookup_with_run_command(self): """Test scope lookup ambiguity after using in lldb.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, @@ -286,7 +286,7 @@ def test_scope_lookup_shadowed_by_using_with_run_command(self): """Test scope lookup shadowed by using in lldb.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, Index: lldb/test/API/lang/cpp/namespace_definitions/TestNamespaceDefinitions.py =================================================================== --- lldb/test/API/lang/cpp/namespace_definitions/TestNamespaceDefinitions.py +++ lldb/test/API/lang/cpp/namespace_definitions/TestNamespaceDefinitions.py @@ -43,7 +43,7 @@ self.dbg.SetAsync(False) # Create a target by the debugger. - target = self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + target = self.dbg.CreateTarget(self.getTestExecutable()) self.assertTrue(target, VALID_TARGET) # Break inside the foo function which takes a bar_ptr argument. Index: lldb/test/API/lang/cpp/non-type-template-param/TestCppNonTypeTemplateParam.py =================================================================== --- lldb/test/API/lang/cpp/non-type-template-param/TestCppNonTypeTemplateParam.py +++ lldb/test/API/lang/cpp/non-type-template-param/TestCppNonTypeTemplateParam.py @@ -10,7 +10,7 @@ @no_debug_info_test def test(self): self.build() - self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + self.dbg.CreateTarget(self.getTestExecutable()) self.expect_expr("myArray", result_type="array<3>", result_children=[ ValueCheck(name="Arr", type="int[3]") Index: lldb/test/API/lang/cpp/nsimport/TestCppNsImport.py =================================================================== --- lldb/test/API/lang/cpp/nsimport/TestCppNsImport.py +++ lldb/test/API/lang/cpp/nsimport/TestCppNsImport.py @@ -21,7 +21,7 @@ self.assertTrue(src_file_spec.IsValid(), "Main source file") # Get the path of the executable - exe_path = self.getBuildArtifact("a.out") + exe_path = self.getTestExecutable() # Load the executable target = self.dbg.CreateTarget(exe_path) Index: lldb/test/API/lang/cpp/pointer_to_member_type_depending_on_parent_size/TestPointerToMemberTypeDependingOnParentSize.py =================================================================== --- lldb/test/API/lang/cpp/pointer_to_member_type_depending_on_parent_size/TestPointerToMemberTypeDependingOnParentSize.py +++ lldb/test/API/lang/cpp/pointer_to_member_type_depending_on_parent_size/TestPointerToMemberTypeDependingOnParentSize.py @@ -23,7 +23,7 @@ parsed). """ self.build() - self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + self.dbg.CreateTarget(self.getTestExecutable()) # Force the record layout for 'ToLayout' to be generated by printing # a value of it's type. Index: lldb/test/API/lang/cpp/reference-to-outer-type/TestCppReferenceToOuterClass.py =================================================================== --- lldb/test/API/lang/cpp/reference-to-outer-type/TestCppReferenceToOuterClass.py +++ lldb/test/API/lang/cpp/reference-to-outer-type/TestCppReferenceToOuterClass.py @@ -10,7 +10,7 @@ @expectedFailure("The fix for this was reverted due to llvm.org/PR52257") def test(self): self.build() - self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + self.dbg.CreateTarget(self.getTestExecutable()) test_var = self.expect_expr("test_var", result_type="In") nested_member = test_var.GetChildMemberWithName('NestedClassMember') self.assertEqual("Outer::NestedClass", Index: lldb/test/API/lang/cpp/rvalue-references/TestRvalueReferences.py =================================================================== --- lldb/test/API/lang/cpp/rvalue-references/TestRvalueReferences.py +++ lldb/test/API/lang/cpp/rvalue-references/TestRvalueReferences.py @@ -19,7 +19,7 @@ def test_with_run_command(self): """Test that rvalues are supported in the C++ expression parser""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) self.set_breakpoint(line_number('main.cpp', '// breakpoint 1')) self.set_breakpoint(line_number('main.cpp', '// breakpoint 2')) Index: lldb/test/API/lang/cpp/signed_types/TestSignedTypes.py =================================================================== --- lldb/test/API/lang/cpp/signed_types/TestSignedTypes.py +++ lldb/test/API/lang/cpp/signed_types/TestSignedTypes.py @@ -31,7 +31,7 @@ self.dbg.SetAsync(False) # Create a target by the debugger. - target = self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + target = self.dbg.CreateTarget(self.getTestExecutable()) self.assertTrue(target, VALID_TARGET) lldbutil.run_break_set_by_file_and_line( Index: lldb/test/API/lang/cpp/static_member_type_depending_on_parent_size/TestStaticMemberTypeDependingOnParentSize.py =================================================================== --- lldb/test/API/lang/cpp/static_member_type_depending_on_parent_size/TestStaticMemberTypeDependingOnParentSize.py +++ lldb/test/API/lang/cpp/static_member_type_depending_on_parent_size/TestStaticMemberTypeDependingOnParentSize.py @@ -15,7 +15,7 @@ for those types while parsing the members from debug info. """ self.build() - self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + self.dbg.CreateTarget(self.getTestExecutable()) # Force the record layout for 'ToLayout' to be generated by printing # a value of it's type. Index: lldb/test/API/lang/cpp/template-arguments/TestCppTemplateArguments.py =================================================================== --- lldb/test/API/lang/cpp/template-arguments/TestCppTemplateArguments.py +++ lldb/test/API/lang/cpp/template-arguments/TestCppTemplateArguments.py @@ -10,7 +10,7 @@ @no_debug_info_test def test(self): self.build() - self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + self.dbg.CreateTarget(self.getTestExecutable()) value = self.expect_expr("temp1", result_type="C") template_type = value.GetType() Index: lldb/test/API/lang/cpp/template/TestTemplateArgs.py =================================================================== --- lldb/test/API/lang/cpp/template/TestTemplateArgs.py +++ lldb/test/API/lang/cpp/template/TestTemplateArgs.py @@ -19,7 +19,7 @@ self.build() # Create a target by the debugger. - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/lang/cpp/this/TestCPPThis.py =================================================================== --- lldb/test/API/lang/cpp/this/TestCPPThis.py +++ lldb/test/API/lang/cpp/this/TestCPPThis.py @@ -24,7 +24,7 @@ def test_with_run_command(self): """Test that the appropriate member variables are available when stopped in C++ static, inline, and const methods""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) self.set_breakpoint(line_number('main.cpp', '// breakpoint 1')) self.set_breakpoint(line_number('main.cpp', '// breakpoint 2')) Index: lldb/test/API/lang/cpp/thread_local/TestThreadLocal.py =================================================================== --- lldb/test/API/lang/cpp/thread_local/TestThreadLocal.py +++ lldb/test/API/lang/cpp/thread_local/TestThreadLocal.py @@ -16,7 +16,7 @@ # Set a breakpoint on the first instruction of the main function, # before the TLS initialization has run. self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() (target, process, _, _) = \ lldbutil.run_to_source_breakpoint(self, "Set breakpoint here", Index: lldb/test/API/lang/mixed/TestMixedLanguages.py =================================================================== --- lldb/test/API/lang/mixed/TestMixedLanguages.py +++ lldb/test/API/lang/mixed/TestMixedLanguages.py @@ -14,7 +14,7 @@ def test_language_of_frame(self): """Test that the language defaults to the language of the current frame.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Execute the cleanup function during test case tear down Index: lldb/test/API/lang/objc/blocks/TestObjCIvarsInBlocks.py =================================================================== --- lldb/test/API/lang/objc/blocks/TestObjCIvarsInBlocks.py +++ lldb/test/API/lang/objc/blocks/TestObjCIvarsInBlocks.py @@ -26,7 +26,7 @@ def test_with_python_api(self): """Test printing the ivars of the self when captured in blocks""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/lang/objc/conflicting-definition/TestConflictingDefinition.py =================================================================== --- lldb/test/API/lang/objc/conflicting-definition/TestConflictingDefinition.py +++ lldb/test/API/lang/objc/conflicting-definition/TestConflictingDefinition.py @@ -41,7 +41,7 @@ "42"]) def common_setup(self): - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.registerSharedLibrariesWithTarget(target, self.shlib_names) Index: lldb/test/API/lang/objc/exceptions/TestObjCExceptions.py =================================================================== --- lldb/test/API/lang/objc/exceptions/TestObjCExceptions.py +++ lldb/test/API/lang/objc/exceptions/TestObjCExceptions.py @@ -18,7 +18,7 @@ def test_objc_exceptions_at_throw(self): self.build() - target = self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + target = self.dbg.CreateTarget(self.getTestExecutable()) self.assertTrue(target, VALID_TARGET) launch_info = lldb.SBLaunchInfo(["a.out", "0"]) @@ -128,7 +128,7 @@ def test_objc_exceptions_at_abort(self): self.build() - target = self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + target = self.dbg.CreateTarget(self.getTestExecutable()) self.assertTrue(target, VALID_TARGET) self.runCmd("run 0") @@ -184,7 +184,7 @@ def test_cxx_exceptions_at_abort(self): self.build() - target = self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + target = self.dbg.CreateTarget(self.getTestExecutable()) self.assertTrue(target, VALID_TARGET) self.runCmd("run 2") Index: lldb/test/API/lang/objc/forward-decl/TestForwardDecl.py =================================================================== --- lldb/test/API/lang/objc/forward-decl/TestForwardDecl.py +++ lldb/test/API/lang/objc/forward-decl/TestForwardDecl.py @@ -24,7 +24,7 @@ self.build(dictionary=dictionary) # Create a target by the debugger. - target = self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + target = self.dbg.CreateTarget(self.getTestExecutable()) self.assertTrue(target, VALID_TARGET) # Create the breakpoint inside function 'main'. Index: lldb/test/API/lang/objc/foundation/TestConstStrings.py =================================================================== --- lldb/test/API/lang/objc/foundation/TestConstStrings.py +++ lldb/test/API/lang/objc/foundation/TestConstStrings.py @@ -28,7 +28,7 @@ self.build(dictionary=self.d) self.setTearDownCleanup(self.d) - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( Index: lldb/test/API/lang/objc/foundation/TestFoundationDisassembly.py =================================================================== --- lldb/test/API/lang/objc/foundation/TestFoundationDisassembly.py +++ lldb/test/API/lang/objc/foundation/TestFoundationDisassembly.py @@ -25,7 +25,7 @@ self.dbg.SetAsync(False) # Create a target by the debugger. - target = self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + target = self.dbg.CreateTarget(self.getTestExecutable()) self.assertTrue(target, VALID_TARGET) # Now launch the process, and do not stop at entry point. @@ -68,7 +68,7 @@ self.build() # Create a target by the debugger. - target = self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + target = self.dbg.CreateTarget(self.getTestExecutable()) self.assertTrue(target, VALID_TARGET) # Stop at +[NSString stringWithFormat:]. Index: lldb/test/API/lang/objc/foundation/TestObjCMethods.py =================================================================== --- lldb/test/API/lang/objc/foundation/TestObjCMethods.py +++ lldb/test/API/lang/objc/foundation/TestObjCMethods.py @@ -32,7 +32,7 @@ def test_break(self): """Test setting objc breakpoints using '_regexp-break' and 'breakpoint set'.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Stop at +[NSString stringWithFormat:]. @@ -114,7 +114,7 @@ def test_data_type_and_expr(self): """Lookup objective-c data types and evaluate expressions.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Stop at -[MyString description]. @@ -227,7 +227,7 @@ self.build() # See: lldb needs to use the ObjC runtime symbols for ivar offsets # Only fails for the ObjC 2.0 runtime. - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) @@ -277,7 +277,7 @@ def test_expression_lookups_objc(self): """Test running an expression detect spurious debug info lookups (DWARF).""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Stop at -[MyString initWithNSString:]. Index: lldb/test/API/lang/objc/foundation/TestRuntimeTypes.py =================================================================== --- lldb/test/API/lang/objc/foundation/TestRuntimeTypes.py +++ lldb/test/API/lang/objc/foundation/TestRuntimeTypes.py @@ -21,7 +21,7 @@ def test_break(self): """Test setting objc breakpoints using '_regexp-break' and 'breakpoint set'.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Stop at -[MyString description]. Index: lldb/test/API/lang/objc/foundation/TestSymbolTable.py =================================================================== --- lldb/test/API/lang/objc/foundation/TestSymbolTable.py +++ lldb/test/API/lang/objc/foundation/TestSymbolTable.py @@ -28,7 +28,7 @@ def test_with_python_api(self): """Test symbol table access with Python APIs.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/lang/objc/global_ptrs/TestGlobalObjects.py =================================================================== --- lldb/test/API/lang/objc/global_ptrs/TestGlobalObjects.py +++ lldb/test/API/lang/objc/global_ptrs/TestGlobalObjects.py @@ -21,7 +21,7 @@ def test_with_python_api(self): """Test that a global ObjC object found before the process is started updates correctly.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/lang/objc/hidden-ivars/TestHiddenIvars.py =================================================================== --- lldb/test/API/lang/objc/hidden-ivars/TestHiddenIvars.py +++ lldb/test/API/lang/objc/hidden-ivars/TestHiddenIvars.py @@ -77,7 +77,7 @@ if strip: exe = self.getBuildArtifact("stripped/a.out") else: - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/lang/objc/ivar-IMP/TestObjCiVarIMP.py =================================================================== --- lldb/test/API/lang/objc/ivar-IMP/TestObjCiVarIMP.py +++ lldb/test/API/lang/objc/ivar-IMP/TestObjCiVarIMP.py @@ -20,7 +20,7 @@ def test_imp_ivar_type(self): """Test that dynamically discovered ivars of type IMP do not crash LLDB""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target from the debugger. target = self.dbg.CreateTarget(exe) Index: lldb/test/API/lang/objc/modules-auto-import/TestModulesAutoImport.py =================================================================== --- lldb/test/API/lang/objc/modules-auto-import/TestModulesAutoImport.py +++ lldb/test/API/lang/objc/modules-auto-import/TestModulesAutoImport.py @@ -23,7 +23,7 @@ @skipIf(macos_version=["<", "10.12"]) def test_expr(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Break inside the foo function which takes a bar_ptr argument. Index: lldb/test/API/lang/objc/modules-incomplete/TestIncompleteModules.py =================================================================== --- lldb/test/API/lang/objc/modules-incomplete/TestIncompleteModules.py +++ lldb/test/API/lang/objc/modules-incomplete/TestIncompleteModules.py @@ -22,7 +22,7 @@ @skipIf(debug_info=no_match(["gmodules"])) def test_expr(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.m", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/lang/objc/modules-inline-functions/TestModulesInlineFunctions.py =================================================================== --- lldb/test/API/lang/objc/modules-inline-functions/TestModulesInlineFunctions.py +++ lldb/test/API/lang/objc/modules-inline-functions/TestModulesInlineFunctions.py @@ -18,7 +18,7 @@ @skipIf(macos_version=["<", "10.12"], debug_info=no_match(["gmodules"])) def test_expr(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Break inside the foo function which takes a bar_ptr argument. Index: lldb/test/API/lang/objc/modules/TestObjCModules.py =================================================================== --- lldb/test/API/lang/objc/modules/TestObjCModules.py +++ lldb/test/API/lang/objc/modules/TestObjCModules.py @@ -23,7 +23,7 @@ @skipIf(macos_version=["<", "10.12"]) def test_expr(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Break inside the foo function which takes a bar_ptr argument. Index: lldb/test/API/lang/objc/objc++/TestObjCXX.py =================================================================== --- lldb/test/API/lang/objc/objc++/TestObjCXX.py +++ lldb/test/API/lang/objc/objc++/TestObjCXX.py @@ -20,7 +20,7 @@ self.skipTest("requires Objective-C 2.0 runtime") self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_source_regexp( Index: lldb/test/API/lang/objc/objc-baseclass-sbtype/TestObjCBaseClassSBType.py =================================================================== --- lldb/test/API/lang/objc/objc-baseclass-sbtype/TestObjCBaseClassSBType.py +++ lldb/test/API/lang/objc/objc-baseclass-sbtype/TestObjCBaseClassSBType.py @@ -28,7 +28,7 @@ self.skipTest("Dynamic types for ObjC V1 runtime not implemented") self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target from the debugger. Index: lldb/test/API/lang/objc/objc-checker/TestObjCCheckers.py =================================================================== --- lldb/test/API/lang/objc/objc-checker/TestObjCCheckers.py +++ lldb/test/API/lang/objc/objc-checker/TestObjCCheckers.py @@ -30,7 +30,7 @@ self.skipTest("requires Objective-C 2.0 runtime") self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target from the debugger. Index: lldb/test/API/lang/objc/objc-class-method/TestObjCClassMethod.py =================================================================== --- lldb/test/API/lang/objc/objc-class-method/TestObjCClassMethod.py +++ lldb/test/API/lang/objc/objc-class-method/TestObjCClassMethod.py @@ -25,7 +25,7 @@ def test_with_python_api(self): """Test calling functions in class methods.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/lang/objc/objc-dynamic-value/TestObjCDynamicValue.py =================================================================== --- lldb/test/API/lang/objc/objc-dynamic-value/TestObjCDynamicValue.py +++ lldb/test/API/lang/objc/objc-dynamic-value/TestObjCDynamicValue.py @@ -38,7 +38,7 @@ self.skipTest("Dynamic types for ObjC V1 runtime not implemented") self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target from the debugger. Index: lldb/test/API/lang/objc/objc-ivar-offsets/TestObjCIvarOffsets.py =================================================================== --- lldb/test/API/lang/objc/objc-ivar-offsets/TestObjCIvarOffsets.py +++ lldb/test/API/lang/objc/objc-ivar-offsets/TestObjCIvarOffsets.py @@ -24,7 +24,7 @@ def test_with_python_api(self): """Test printing ObjC objects that use unbacked properties""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/lang/objc/objc-optimized/TestObjcOptimized.py =================================================================== --- lldb/test/API/lang/objc/objc-optimized/TestObjcOptimized.py +++ lldb/test/API/lang/objc/objc-optimized/TestObjcOptimized.py @@ -30,7 +30,7 @@ def test_break(self): """Test 'expr member' continues to work for optimized build.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_symbol( Index: lldb/test/API/lang/objc/objc-property/TestObjCProperty.py =================================================================== --- lldb/test/API/lang/objc/objc-property/TestObjCProperty.py +++ lldb/test/API/lang/objc/objc-property/TestObjCProperty.py @@ -28,7 +28,7 @@ self.skipTest("requires modern objc runtime") self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target from the debugger. Index: lldb/test/API/lang/objc/objc-static-method-stripped/TestObjCStaticMethodStripped.py =================================================================== --- lldb/test/API/lang/objc/objc-static-method-stripped/TestObjCStaticMethodStripped.py +++ lldb/test/API/lang/objc/objc-static-method-stripped/TestObjCStaticMethodStripped.py @@ -30,7 +30,7 @@ if self.getArchitecture() == 'i386': self.skipTest("requires modern objc runtime") self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/lang/objc/objc-static-method/TestObjCStaticMethod.py =================================================================== --- lldb/test/API/lang/objc/objc-static-method/TestObjCStaticMethod.py +++ lldb/test/API/lang/objc/objc-static-method/TestObjCStaticMethod.py @@ -25,7 +25,7 @@ def test_with_python_api(self): """Test calling functions in static methods.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/lang/objc/objc-stepping/TestObjCStepping.py =================================================================== --- lldb/test/API/lang/objc/objc-stepping/TestObjCStepping.py +++ lldb/test/API/lang/objc/objc-stepping/TestObjCStepping.py @@ -33,7 +33,7 @@ def test_with_python_api(self): """Test stepping through ObjC method dispatch in various forms.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/lang/objc/objc-struct-argument/TestObjCStructArgument.py =================================================================== --- lldb/test/API/lang/objc/objc-struct-argument/TestObjCStructArgument.py +++ lldb/test/API/lang/objc/objc-struct-argument/TestObjCStructArgument.py @@ -25,7 +25,7 @@ def test_with_python_api(self): """Test passing structs to Objective-C methods.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/lang/objc/objc-struct-return/TestObjCStructReturn.py =================================================================== --- lldb/test/API/lang/objc/objc-struct-return/TestObjCStructReturn.py +++ lldb/test/API/lang/objc/objc-struct-return/TestObjCStructReturn.py @@ -24,7 +24,7 @@ def test_with_python_api(self): """Test calling functions in class methods.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/lang/objc/objc-super/TestObjCSuper.py =================================================================== --- lldb/test/API/lang/objc/objc-super/TestObjCSuper.py +++ lldb/test/API/lang/objc/objc-super/TestObjCSuper.py @@ -24,7 +24,7 @@ def test_with_python_api(self): """Test calling methods on super.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/lang/objc/ptr_refs/TestPtrRefsObjC.py =================================================================== --- lldb/test/API/lang/objc/ptr_refs/TestPtrRefsObjC.py +++ lldb/test/API/lang/objc/ptr_refs/TestPtrRefsObjC.py @@ -17,7 +17,7 @@ def test_ptr_refs(self): """Test the ptr_refs tool on Darwin with Objective-C""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/lang/objc/self/TestObjCSelf.py =================================================================== --- lldb/test/API/lang/objc/self/TestObjCSelf.py +++ lldb/test/API/lang/objc/self/TestObjCSelf.py @@ -14,7 +14,7 @@ def test_with_run_command(self): """Test that the appropriate member variables are available when stopped in Objective-C class and instance methods""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) self.set_breakpoint(line_number('main.m', '// breakpoint 1')) self.set_breakpoint(line_number('main.m', '// breakpoint 2')) Index: lldb/test/API/lang/objc/single-entry-dictionary/TestObjCSingleEntryDictionary.py =================================================================== --- lldb/test/API/lang/objc/single-entry-dictionary/TestObjCSingleEntryDictionary.py +++ lldb/test/API/lang/objc/single-entry-dictionary/TestObjCSingleEntryDictionary.py @@ -42,7 +42,7 @@ self.run_tests() def run_tests(self): - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Break inside the foo function which takes a bar_ptr argument. Index: lldb/test/API/lang/objcxx/objc-builtin-types/TestObjCBuiltinTypes.py =================================================================== --- lldb/test/API/lang/objcxx/objc-builtin-types/TestObjCBuiltinTypes.py +++ lldb/test/API/lang/objcxx/objc-builtin-types/TestObjCBuiltinTypes.py @@ -22,7 +22,7 @@ def test_with_python_api(self): """Test expression parser respect for ObjC built-in types.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/linux/aarch64/mte_memory_region/TestAArch64LinuxMTEMemoryRegion.py =================================================================== --- lldb/test/API/linux/aarch64/mte_memory_region/TestAArch64LinuxMTEMemoryRegion.py +++ lldb/test/API/linux/aarch64/mte_memory_region/TestAArch64LinuxMTEMemoryRegion.py @@ -31,7 +31,7 @@ # before MTE was supported at all. self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line(self, "main.c", line_number('main.c', '// Set break point at this line.'), Index: lldb/test/API/linux/aarch64/mte_tag_access/TestAArch64LinuxMTEMemoryTagAccess.py =================================================================== --- lldb/test/API/linux/aarch64/mte_tag_access/TestAArch64LinuxMTEMemoryTagAccess.py +++ lldb/test/API/linux/aarch64/mte_tag_access/TestAArch64LinuxMTEMemoryTagAccess.py @@ -26,7 +26,7 @@ self.skipTest('Target must support pointer authentication') self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line(self, "main.c", line_number('main.c', '// Breakpoint here'), Index: lldb/test/API/linux/aarch64/mte_tag_faults/TestAArch64LinuxMTEMemoryTagFaults.py =================================================================== --- lldb/test/API/linux/aarch64/mte_tag_faults/TestAArch64LinuxMTEMemoryTagFaults.py +++ lldb/test/API/linux/aarch64/mte_tag_faults/TestAArch64LinuxMTEMemoryTagFaults.py @@ -20,7 +20,7 @@ self.skipTest('Target must support MTE.') self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line(self, "main.c", line_number('main.c', '// Breakpoint here'), Index: lldb/test/API/linux/aarch64/non_address_bit_memory_access/TestAArch64LinuxNonAddressBitMemoryAccess.py =================================================================== --- lldb/test/API/linux/aarch64/non_address_bit_memory_access/TestAArch64LinuxNonAddressBitMemoryAccess.py +++ lldb/test/API/linux/aarch64/non_address_bit_memory_access/TestAArch64LinuxNonAddressBitMemoryAccess.py @@ -25,7 +25,7 @@ self.skipTest('Target must support pointer authentication.') self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line(self, "main.c", line_number('main.c', '// Set break point at this line.'), Index: lldb/test/API/linux/aarch64/tagged_memory_access/TestAArch64LinuxTaggedMemoryAccess.py =================================================================== --- lldb/test/API/linux/aarch64/tagged_memory_access/TestAArch64LinuxTaggedMemoryAccess.py +++ lldb/test/API/linux/aarch64/tagged_memory_access/TestAArch64LinuxTaggedMemoryAccess.py @@ -22,7 +22,7 @@ def setup_test(self): self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line(self, "main.c", line_number('main.c', '// Set break point at this line.'), Index: lldb/test/API/linux/aarch64/tagged_memory_region/TestAArch64LinuxTaggedMemoryRegion.py =================================================================== --- lldb/test/API/linux/aarch64/tagged_memory_region/TestAArch64LinuxTaggedMemoryRegion.py +++ lldb/test/API/linux/aarch64/tagged_memory_region/TestAArch64LinuxTaggedMemoryRegion.py @@ -22,7 +22,7 @@ @skipUnlessPlatform(["linux"]) def test_mte_regions(self): self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line(self, "main.c", line_number('main.c', '// Set break point at this line.'), Index: lldb/test/API/linux/aarch64/unwind_signal/TestUnwindSignal.py =================================================================== --- lldb/test/API/linux/aarch64/unwind_signal/TestUnwindSignal.py +++ lldb/test/API/linux/aarch64/unwind_signal/TestUnwindSignal.py @@ -21,7 +21,7 @@ Stopped at a breakpoint in the handler, check that we can unwind back to sigill() and get the expected register contents there.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/linux/add-symbols/TestTargetSymbolsAddCommand.py =================================================================== --- lldb/test/API/linux/add-symbols/TestTargetSymbolsAddCommand.py +++ lldb/test/API/linux/add-symbols/TestTargetSymbolsAddCommand.py @@ -44,7 +44,7 @@ # Tell LLDB that a.out has symbols for stripped.out self.runCmd("target symbols add -s %s %s" % - (exe, self.getBuildArtifact("a.out"))) + (exe, self.getTestExecutable())) # Check that symbols are now loaded and main.c is in the output. self.expect("frame select", substrs=['main.c']) Index: lldb/test/API/linux/builtin_trap/TestBuiltinTrap.py =================================================================== --- lldb/test/API/linux/builtin_trap/TestBuiltinTrap.py +++ lldb/test/API/linux/builtin_trap/TestBuiltinTrap.py @@ -28,7 +28,7 @@ def test_with_run_command(self): """Test that LLDB handles a function with __builtin_trap correctly.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line(self, "main.cpp", self.line, num_expected_locations=1, Index: lldb/test/API/linux/mix-dwo-and-regular-objects/TestMixedDwarfBinary.py =================================================================== --- lldb/test/API/linux/mix-dwo-and-regular-objects/TestMixedDwarfBinary.py +++ lldb/test/API/linux/mix-dwo-and-regular-objects/TestMixedDwarfBinary.py @@ -17,7 +17,7 @@ with/whithout -gsplit-dwarf correspondingly.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.target = self.dbg.CreateTarget(exe) self.assertTrue(self.target, VALID_TARGET) Index: lldb/test/API/linux/thread/create_during_instruction_step/TestCreateDuringInstructionStep.py =================================================================== --- lldb/test/API/linux/thread/create_during_instruction_step/TestCreateDuringInstructionStep.py +++ lldb/test/API/linux/thread/create_during_instruction_step/TestCreateDuringInstructionStep.py @@ -20,7 +20,7 @@ @skipIf(oslist=["linux"], archs=["arm", "aarch64"], bugnumber="llvm.org/pr24737") def test_step_inst(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target and target.IsValid(), "Target is valid") Index: lldb/test/API/lua_api/TestLuaAPI.py =================================================================== --- lldb/test/API/lua_api/TestLuaAPI.py +++ lldb/test/API/lua_api/TestLuaAPI.py @@ -158,7 +158,7 @@ lua_executable = os.environ["LUA_EXECUTABLE"] self.build() - test_exe = self.getBuildArtifact("a.out") + test_exe = self.getTestExecutable() test_output = self.getBuildArtifact("output") test_input = self.getBuildArtifact("input") Index: lldb/test/API/macosx/add-dsym/TestAddDsymDownload.py =================================================================== --- lldb/test/API/macosx/add-dsym/TestAddDsymDownload.py +++ lldb/test/API/macosx/add-dsym/TestAddDsymDownload.py @@ -47,7 +47,7 @@ def setUp(self): TestBase.setUp(self) self.source = 'main.c' - self.exe = self.getBuildArtifact("a.out") + self.exe = self.getTestExecutable() self.dsym = os.path.join( self.getBuildDir(), "hide.app/Contents/a.out.dSYM/Contents/Resources/DWARF/", Index: lldb/test/API/macosx/add-dsym/TestAddDsymMidExecutionCommand.py =================================================================== --- lldb/test/API/macosx/add-dsym/TestAddDsymMidExecutionCommand.py +++ lldb/test/API/macosx/add-dsym/TestAddDsymMidExecutionCommand.py @@ -22,7 +22,7 @@ def test_add_dsym_mid_execution(self): """Test that add-dsym mid-execution loads the symbols at the right place for a slid binary.""" self.build(debug_info="dsym") - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.target = self.dbg.CreateTarget(exe) self.assertTrue(self.target, VALID_TARGET) Index: lldb/test/API/macosx/corefile-default-ptrauth/TestCorefileDefaultPtrauth.py =================================================================== --- lldb/test/API/macosx/corefile-default-ptrauth/TestCorefileDefaultPtrauth.py +++ lldb/test/API/macosx/corefile-default-ptrauth/TestCorefileDefaultPtrauth.py @@ -21,7 +21,7 @@ @skipIfRemote def test_lc_note(self): self.build() - self.test_exe = self.getBuildArtifact("a.out") + self.test_exe = self.getTestExecutable() self.create_corefile = self.getBuildArtifact("create-corefile") self.corefile = self.getBuildArtifact("core") Index: lldb/test/API/macosx/debugserver-exit-code/TestDebugServerExitCode.py =================================================================== --- lldb/test/API/macosx/debugserver-exit-code/TestDebugServerExitCode.py +++ lldb/test/API/macosx/debugserver-exit-code/TestDebugServerExitCode.py @@ -16,7 +16,7 @@ @skipIfOutOfTreeDebugserver def test_abort(self): self.build() - target = self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + target = self.dbg.CreateTarget(self.getTestExecutable()) process = target.LaunchSimple(None, None, None) # Continue until process is terminated. process.Continue() Index: lldb/test/API/macosx/duplicate-archive-members/TestDuplicateMembers.py =================================================================== --- lldb/test/API/macosx/duplicate-archive-members/TestDuplicateMembers.py +++ lldb/test/API/macosx/duplicate-archive-members/TestDuplicateMembers.py @@ -19,7 +19,7 @@ """Break inside a() and b() defined within libfoo.a.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Break on a() and b() symbols Index: lldb/test/API/macosx/dyld-trie-symbols/TestDyldTrieSymbols.py =================================================================== --- lldb/test/API/macosx/dyld-trie-symbols/TestDyldTrieSymbols.py +++ lldb/test/API/macosx/dyld-trie-symbols/TestDyldTrieSymbols.py @@ -19,7 +19,7 @@ def test_dyld_trie_symbols(self): """Test that we make create symbol table entries from the dyld trie data structure.""" self.build() - unstripped_exe = self.getBuildArtifact("a.out") + unstripped_exe = self.getTestExecutable() stripped_exe = self.getBuildArtifact("a.out-stripped") unstripped_target = self.dbg.CreateTarget(unstripped_exe) Index: lldb/test/API/macosx/indirect_symbol/TestIndirectSymbols.py =================================================================== --- lldb/test/API/macosx/indirect_symbol/TestIndirectSymbols.py +++ lldb/test/API/macosx/indirect_symbol/TestIndirectSymbols.py @@ -23,7 +23,7 @@ def test_with_python_api(self): """Test stepping and setting breakpoints in indirect and re-exported symbols.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/macosx/lc-note/addrable-bits/TestAddrableBitsCorefile.py =================================================================== --- lldb/test/API/macosx/lc-note/addrable-bits/TestAddrableBitsCorefile.py +++ lldb/test/API/macosx/lc-note/addrable-bits/TestAddrableBitsCorefile.py @@ -19,7 +19,7 @@ def initial_setup(self): self.build() - self.exe = self.getBuildArtifact("a.out") + self.exe = self.getTestExecutable() self.corefile = self.getBuildArtifact("corefile") @skipIf(archs=no_match(['arm64e'])) Index: lldb/test/API/macosx/lc-note/firmware-corefile/TestFirmwareCorefiles.py =================================================================== --- lldb/test/API/macosx/lc-note/firmware-corefile/TestFirmwareCorefiles.py +++ lldb/test/API/macosx/lc-note/firmware-corefile/TestFirmwareCorefiles.py @@ -161,7 +161,7 @@ def test_lc_note_main_bin_spec_os_plugin(self): self.build() - aout_exe = self.getBuildArtifact("a.out") + aout_exe = self.getTestExecutable() aout_exe_basename = "a.out" create_corefile = self.getBuildArtifact("create-empty-corefile") binspec_corefile_addr = self.getBuildArtifact("binspec-addr.core") Index: lldb/test/API/macosx/lc-note/kern-ver-str/TestKernVerStrLCNOTE.py =================================================================== --- lldb/test/API/macosx/lc-note/kern-ver-str/TestKernVerStrLCNOTE.py +++ lldb/test/API/macosx/lc-note/kern-ver-str/TestKernVerStrLCNOTE.py @@ -21,7 +21,7 @@ @skipUnlessDarwin def test_lc_note(self): self.build() - self.test_exe = self.getBuildArtifact("a.out") + self.test_exe = self.getTestExecutable() self.create_corefile = self.getBuildArtifact("create-empty-corefile") self.dsym_for_uuid = self.getBuildArtifact("dsym-for-uuid.sh") self.corefile = self.getBuildArtifact("core") Index: lldb/test/API/macosx/nslog/TestDarwinNSLogOutput.py =================================================================== --- lldb/test/API/macosx/nslog/TestDarwinNSLogOutput.py +++ lldb/test/API/macosx/nslog/TestDarwinNSLogOutput.py @@ -35,7 +35,7 @@ self.source = 'main.m' # Output filename. - self.exe_name = self.getBuildArtifact("a.out") + self.exe_name = self.getTestExecutable() self.d = {'OBJC_SOURCES': self.source, 'EXE': self.exe_name} # Locate breakpoint. Index: lldb/test/API/macosx/order/TestOrderFile.py =================================================================== --- lldb/test/API/macosx/order/TestOrderFile.py +++ lldb/test/API/macosx/order/TestOrderFile.py @@ -19,7 +19,7 @@ def test(self): """Test debug symbols follow the correct order by the order file.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Test that the debug symbols have Function f3 before Function f1. Index: lldb/test/API/macosx/queues/TestQueues.py =================================================================== --- lldb/test/API/macosx/queues/TestQueues.py +++ lldb/test/API/macosx/queues/TestQueues.py @@ -126,7 +126,7 @@ def queues(self): """Test queues inspection SB APIs without libBacktraceRecording.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) @@ -254,7 +254,7 @@ @skipIfDarwin # rdar://50379398 def queues_with_libBacktraceRecording(self): """Test queues inspection SB APIs with libBacktraceRecording present.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() if not os.path.isfile( '/Applications/Xcode.app/Contents/Developer/usr/lib/libBacktraceRecording.dylib'): Index: lldb/test/API/macosx/safe-to-func-call/TestSafeFuncCalls.py =================================================================== --- lldb/test/API/macosx/safe-to-func-call/TestSafeFuncCalls.py +++ lldb/test/API/macosx/safe-to-func-call/TestSafeFuncCalls.py @@ -17,7 +17,7 @@ def test_with_python_api(self): """Test function call thread safety.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/macosx/simulator/TestSimulatorPlatform.py =================================================================== --- lldb/test/API/macosx/simulator/TestSimulatorPlatform.py +++ lldb/test/API/macosx/simulator/TestSimulatorPlatform.py @@ -14,7 +14,7 @@ def check_load_commands(self, expected_load_command): """sanity check the built binary for the expected number of load commands""" load_cmds = subprocess.check_output( - ['otool', '-l', self.getBuildArtifact("a.out")] + ['otool', '-l', self.getTestExecutable()] ).decode("utf-8") found = 0 for line in load_cmds.split('\n'): Index: lldb/test/API/macosx/skinny-corefile/TestSkinnyCorefile.py =================================================================== --- lldb/test/API/macosx/skinny-corefile/TestSkinnyCorefile.py +++ lldb/test/API/macosx/skinny-corefile/TestSkinnyCorefile.py @@ -22,7 +22,7 @@ @skipIfRemote def test_lc_note(self): self.build() - self.aout_exe = self.getBuildArtifact("a.out") + self.aout_exe = self.getTestExecutable() self.aout_dsym = self.getBuildArtifact("a.out.dSYM") self.to_be_removed_dylib = self.getBuildArtifact("libto-be-removed.dylib") self.to_be_removed_dsym = self.getBuildArtifact("libto-be-removed.dylib.dSYM") Index: lldb/test/API/macosx/thread-names/TestInterruptThreadNames.py =================================================================== --- lldb/test/API/macosx/thread-names/TestInterruptThreadNames.py +++ lldb/test/API/macosx/thread-names/TestInterruptThreadNames.py @@ -17,7 +17,7 @@ def test_with_python_api(self): """Test that we get thread names when interrupting a process.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/python_api/breakpoint/TestBreakpointAPI.py =================================================================== --- lldb/test/API/python_api/breakpoint/TestBreakpointAPI.py +++ lldb/test/API/python_api/breakpoint/TestBreakpointAPI.py @@ -16,7 +16,7 @@ def test_breakpoint_is_valid(self): """Make sure that if an SBBreakpoint gets deleted its IsValid returns false.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) @@ -49,7 +49,7 @@ Breakpoint's IsValid returns false.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) Index: lldb/test/API/python_api/debugger/TestDebuggerAPI.py =================================================================== --- lldb/test/API/python_api/debugger/TestDebuggerAPI.py +++ lldb/test/API/python_api/debugger/TestDebuggerAPI.py @@ -46,7 +46,7 @@ """Ensure that SBDebugger reachs the same instance of properties regardless CommandInterpreter's context initialization""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) @@ -94,7 +94,7 @@ self.assertEqual(get_cache_line_size(), new_cache_line_size) def test_CreateTarget_platform(self): - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.yaml2obj("elf.yaml", exe) error = lldb.SBError() target1 = self.dbg.CreateTarget(exe, None, "remote-linux", @@ -120,7 +120,7 @@ self.assertIsNone(platform3.GetWorkingDirectory()) def test_CreateTarget_arch(self): - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() if lldbplatformutil.getHostPlatform() == 'linux': self.yaml2obj("macho.yaml", exe) arch = "x86_64-apple-macosx" Index: lldb/test/API/python_api/event/TestEvents.py =================================================================== --- lldb/test/API/python_api/event/TestEvents.py +++ lldb/test/API/python_api/event/TestEvents.py @@ -33,7 +33,7 @@ def test_listen_for_and_print_event(self): """Exercise SBEvent API.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.dbg.SetAsync(True) @@ -123,7 +123,7 @@ def test_wait_for_event(self): """Exercise SBListener.WaitForEvent() API.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.dbg.SetAsync(True) @@ -204,7 +204,7 @@ def test_add_listener_to_broadcaster(self): """Exercise some SBBroadcaster APIs.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.dbg.SetAsync(True) Index: lldb/test/API/python_api/findvalue_duplist/TestSBFrameFindValue.py =================================================================== --- lldb/test/API/python_api/findvalue_duplist/TestSBFrameFindValue.py +++ lldb/test/API/python_api/findvalue_duplist/TestSBFrameFindValue.py @@ -18,7 +18,7 @@ self.build() self.setTearDownCleanup() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create the target target = self.dbg.CreateTarget(exe) Index: lldb/test/API/python_api/formatters/TestFormattersSBAPI.py =================================================================== --- lldb/test/API/python_api/formatters/TestFormattersSBAPI.py +++ lldb/test/API/python_api/formatters/TestFormattersSBAPI.py @@ -25,7 +25,7 @@ self.setTearDownCleanup() """Test Python APIs for working with formatters""" - self.runCmd("file " + self.getBuildArtifact("a.out"), + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( Index: lldb/test/API/python_api/frame/TestFrames.py =================================================================== --- lldb/test/API/python_api/frame/TestFrames.py +++ lldb/test/API/python_api/frame/TestFrames.py @@ -19,7 +19,7 @@ def test_get_arg_vals_for_call_stack(self): """Exercise SBFrame.GetVariables() API to get argument vals.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) @@ -122,7 +122,7 @@ def test_frame_api_boundary_condition(self): """Exercise SBFrame APIs with boundary condition inputs.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) @@ -163,7 +163,7 @@ def test_frame_api_IsEqual(self): """Exercise SBFrame API IsEqual.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) Index: lldb/test/API/python_api/frame/get-variables/TestGetVariables.py =================================================================== --- lldb/test/API/python_api/frame/get-variables/TestGetVariables.py +++ lldb/test/API/python_api/frame/get-variables/TestGetVariables.py @@ -49,7 +49,7 @@ self.dbg.SetAsync(False) # Create a target by the debugger. - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/python_api/frame/inlines/TestInlinedFrame.py =================================================================== --- lldb/test/API/python_api/frame/inlines/TestInlinedFrame.py +++ lldb/test/API/python_api/frame/inlines/TestInlinedFrame.py @@ -28,7 +28,7 @@ def test_stop_at_outer_inline(self): """Exercise SBFrame.IsInlined() and SBFrame.GetFunctionName().""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) Index: lldb/test/API/python_api/function_symbol/TestDisasmAPI.py =================================================================== --- lldb/test/API/python_api/function_symbol/TestDisasmAPI.py +++ lldb/test/API/python_api/function_symbol/TestDisasmAPI.py @@ -28,7 +28,7 @@ def test(self): """Exercise getting SBAddress objects, disassembly, and SBAddress APIs.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) Index: lldb/test/API/python_api/function_symbol/TestSymbolAPI.py =================================================================== --- lldb/test/API/python_api/function_symbol/TestSymbolAPI.py +++ lldb/test/API/python_api/function_symbol/TestSymbolAPI.py @@ -28,7 +28,7 @@ def test(self): """Exercise some SBSymbol and SBAddress APIs.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) Index: lldb/test/API/python_api/interpreter/TestCommandInterpreterAPI.py =================================================================== --- lldb/test/API/python_api/interpreter/TestCommandInterpreterAPI.py +++ lldb/test/API/python_api/interpreter/TestCommandInterpreterAPI.py @@ -23,7 +23,7 @@ def test_with_process_launch_api(self): """Test the SBCommandInterpreter APIs.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) Index: lldb/test/API/python_api/lldbutil/frame/TestFrameUtils.py =================================================================== --- lldb/test/API/python_api/lldbutil/frame/TestFrameUtils.py +++ lldb/test/API/python_api/lldbutil/frame/TestFrameUtils.py @@ -25,7 +25,7 @@ def test_frame_utils(self): """Test utility functions for the frame object.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/python_api/lldbutil/iter/TestLLDBIterator.py =================================================================== --- lldb/test/API/python_api/lldbutil/iter/TestLLDBIterator.py +++ lldb/test/API/python_api/lldbutil/iter/TestLLDBIterator.py @@ -26,7 +26,7 @@ def test_lldb_iter_module(self): """Test module_iter works correctly for SBTarget -> SBModule.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) @@ -61,7 +61,7 @@ def test_lldb_iter_breakpoint(self): """Test breakpoint_iter works correctly for SBTarget -> SBBreakpoint.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) @@ -93,7 +93,7 @@ def test_lldb_iter_frame(self): """Test iterator works correctly for SBProcess->SBThread->SBFrame.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/python_api/lldbutil/iter/TestRegistersIterator.py =================================================================== --- lldb/test/API/python_api/lldbutil/iter/TestRegistersIterator.py +++ lldb/test/API/python_api/lldbutil/iter/TestRegistersIterator.py @@ -25,7 +25,7 @@ def test_iter_registers(self): """Test iterator works correctly for lldbutil.iter_registers().""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/python_api/module_section/TestModuleAndSection.py =================================================================== --- lldb/test/API/python_api/module_section/TestModuleAndSection.py +++ lldb/test/API/python_api/module_section/TestModuleAndSection.py @@ -22,7 +22,7 @@ def test_module_and_section(self): """Test module and section APIs.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) @@ -73,7 +73,7 @@ def test_module_and_section_boundary_condition(self): """Test module and section APIs by passing None when it expects a Python string.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) @@ -113,7 +113,7 @@ def test_module_compile_unit_iter(self): """Test module's compile unit iterator APIs.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/python_api/name_lookup/TestNameLookup.py =================================================================== --- lldb/test/API/python_api/name_lookup/TestNameLookup.py +++ lldb/test/API/python_api/name_lookup/TestNameLookup.py @@ -24,7 +24,7 @@ and that using a function basename with eFunctionNameTypeFull works for all C++ functions that are at the global namespace level.""" self.build(); - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) Index: lldb/test/API/python_api/objc_type/TestObjCType.py =================================================================== --- lldb/test/API/python_api/objc_type/TestObjCType.py +++ lldb/test/API/python_api/objc_type/TestObjCType.py @@ -23,7 +23,7 @@ def test(self): """Test SBType for ObjC classes.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) Index: lldb/test/API/python_api/process/TestProcessAPI.py =================================================================== --- lldb/test/API/python_api/process/TestProcessAPI.py +++ lldb/test/API/python_api/process/TestProcessAPI.py @@ -26,7 +26,7 @@ def test_read_memory(self): """Test Python SBProcess.ReadMemory() API.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) @@ -123,7 +123,7 @@ def test_write_memory(self): """Test Python SBProcess.WriteMemory() API.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) @@ -181,7 +181,7 @@ def test_access_my_int(self): """Test access 'my_int' using Python SBProcess.GetByteOrder() and other APIs.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) @@ -278,7 +278,7 @@ def test_remote_launch(self): """Test SBProcess.RemoteLaunch() API with a process not in eStateConnected, and it should fail.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) @@ -301,7 +301,7 @@ def test_get_num_supported_hardware_watchpoints(self): """Test SBProcess.GetNumSupportedHardwareWatchpoints() API with a process.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) target = self.dbg.CreateTarget(exe) @@ -324,7 +324,7 @@ def test_get_process_info(self): """Test SBProcess::GetProcessInfo() API with a locally launched process.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) target = self.dbg.CreateTarget(exe) Index: lldb/test/API/python_api/sbdata/TestSBData.py =================================================================== --- lldb/test/API/python_api/sbdata/TestSBData.py +++ lldb/test/API/python_api/sbdata/TestSBData.py @@ -53,7 +53,7 @@ def test_with_run_command(self): """Test the SBData APIs.""" self.build() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self, "main.cpp", self.line, num_expected_locations=1, loc_exact=True) Index: lldb/test/API/python_api/sbmodule/TestSBModule.py =================================================================== --- lldb/test/API/python_api/sbmodule/TestSBModule.py +++ lldb/test/API/python_api/sbmodule/TestSBModule.py @@ -37,7 +37,7 @@ self.dbg.DeleteTarget(target) self.assertEqual(self.dbg.GetNumTargets(), 0) - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() background_process = subprocess.Popen([exe]) self.assertTrue(background_process, "process is not valid") self.background_pid = background_process.pid Index: lldb/test/API/python_api/sbplatform/TestSBPlatform.py =================================================================== --- lldb/test/API/python_api/sbplatform/TestSBPlatform.py +++ lldb/test/API/python_api/sbplatform/TestSBPlatform.py @@ -17,7 +17,7 @@ def cleanup(): del os.environ["MY_TEST_ENV_VAR"] self.addTearDownHook(cleanup) - cmd = lldb.SBPlatformShellCommand(self.getBuildArtifact("a.out")) + cmd = lldb.SBPlatformShellCommand(self.getTestExecutable()) self.assertSuccess(plat.Run(cmd)) self.assertIn("MY_TEST_ENV_VAR=SBPlatformAPICase.test_run", cmd.GetOutput()) Index: lldb/test/API/python_api/sbvalue_persist/TestSBValuePersist.py =================================================================== --- lldb/test/API/python_api/sbvalue_persist/TestSBValuePersist.py +++ lldb/test/API/python_api/sbvalue_persist/TestSBValuePersist.py @@ -18,7 +18,7 @@ """Test SBValue::Persist""" self.build() self.setTearDownCleanup() - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_source_regexp(self, "break here") Index: lldb/test/API/python_api/signals/TestSignalsAPI.py =================================================================== --- lldb/test/API/python_api/signals/TestSignalsAPI.py +++ lldb/test/API/python_api/signals/TestSignalsAPI.py @@ -19,7 +19,7 @@ def test_ignore_signal(self): """Test Python SBUnixSignals.Suppress/Stop/Notify() API.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) target = self.dbg.CreateTarget(exe) Index: lldb/test/API/python_api/symbol-context/TestSymbolContext.py =================================================================== --- lldb/test/API/python_api/symbol-context/TestSymbolContext.py +++ lldb/test/API/python_api/symbol-context/TestSymbolContext.py @@ -25,7 +25,7 @@ def test(self): """Exercise SBSymbolContext API extensively.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) Index: lldb/test/API/python_api/symbol-context/two-files/TestSymbolContextTwoFiles.py =================================================================== --- lldb/test/API/python_api/symbol-context/two-files/TestSymbolContextTwoFiles.py +++ lldb/test/API/python_api/symbol-context/two-files/TestSymbolContextTwoFiles.py @@ -18,7 +18,7 @@ def test_lookup_by_address(self): """Test lookup by address in a module with multiple compilation units""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) @@ -39,7 +39,7 @@ """This test verifies that we correctly handle the case when multiple compile unit contains DW_AT_ranges and DW_AT_ranges_base attributes.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/python_api/target/TestTargetAPI.py =================================================================== --- lldb/test/API/python_api/target/TestTargetAPI.py +++ lldb/test/API/python_api/target/TestTargetAPI.py @@ -316,7 +316,7 @@ def get_description(self): """Exercise SBTarget.GetDescription() API.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) @@ -346,7 +346,7 @@ def test_launch_new_process_and_redirect_stdout(self): """Exercise SBTarget.Launch() API with redirected stdout.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) @@ -404,7 +404,7 @@ def resolve_symbol_context_with_address(self): """Exercise SBTarget.ResolveSymbolContextForAddress() API.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) @@ -487,7 +487,7 @@ def test_default_arch(self): """ Test the other two target create methods using LLDB_ARCH_DEFAULT. """ self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTargetWithFileAndArch(exe, lldb.LLDB_ARCH_DEFAULT) self.assertTrue(target.IsValid(), "Default arch made a valid target.") # This should also work with the target's triple: Index: lldb/test/API/python_api/thread/TestThreadAPI.py =================================================================== --- lldb/test/API/python_api/thread/TestThreadAPI.py +++ lldb/test/API/python_api/thread/TestThreadAPI.py @@ -72,7 +72,7 @@ def get_process(self): """Test Python SBThread.GetProcess() API.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) @@ -98,7 +98,7 @@ def get_stop_description(self): """Test Python SBThread.GetStopDescription() API.""" - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() target = self.dbg.CreateTarget(exe) self.assertTrue(target, VALID_TARGET) Index: lldb/test/API/python_api/value/empty_class/TestValueAPIEmptyClass.py =================================================================== --- lldb/test/API/python_api/value/empty_class/TestValueAPIEmptyClass.py +++ lldb/test/API/python_api/value/empty_class/TestValueAPIEmptyClass.py @@ -10,7 +10,7 @@ def test(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() line = line_number('main.cpp', '// Break at this line') # Create a target by the debugger. Index: lldb/test/API/python_api/watchpoint/TestSetWatchpoint.py =================================================================== --- lldb/test/API/python_api/watchpoint/TestSetWatchpoint.py +++ lldb/test/API/python_api/watchpoint/TestSetWatchpoint.py @@ -30,7 +30,7 @@ def test_watch_val(self): """Exercise SBValue.Watch() API to set a watchpoint.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) Index: lldb/test/API/python_api/watchpoint/TestWatchpointIgnoreCount.py =================================================================== --- lldb/test/API/python_api/watchpoint/TestWatchpointIgnoreCount.py +++ lldb/test/API/python_api/watchpoint/TestWatchpointIgnoreCount.py @@ -37,7 +37,7 @@ def test_set_watch_ignore_count(self): """Test SBWatchpoint.SetIgnoreCount() API.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) Index: lldb/test/API/python_api/watchpoint/TestWatchpointIter.py =================================================================== --- lldb/test/API/python_api/watchpoint/TestWatchpointIter.py +++ lldb/test/API/python_api/watchpoint/TestWatchpointIter.py @@ -33,7 +33,7 @@ def test_watch_iter(self): """Exercise SBTarget.watchpoint_iter() API to iterate on the available watchpoints.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) Index: lldb/test/API/python_api/watchpoint/watchlocation/TestSetWatchlocation.py =================================================================== --- lldb/test/API/python_api/watchpoint/watchlocation/TestSetWatchlocation.py +++ lldb/test/API/python_api/watchpoint/watchlocation/TestSetWatchlocation.py @@ -32,7 +32,7 @@ def test_watch_location(self): """Exercise SBValue.WatchPointee() API to set a watchpoint.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) Index: lldb/test/API/python_api/watchpoint/watchlocation/TestTargetWatchAddress.py =================================================================== --- lldb/test/API/python_api/watchpoint/watchlocation/TestTargetWatchAddress.py +++ lldb/test/API/python_api/watchpoint/watchlocation/TestTargetWatchAddress.py @@ -30,7 +30,7 @@ def test_watch_address(self): """Exercise SBTarget.WatchAddress() API to set a watchpoint.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) @@ -104,7 +104,7 @@ def test_watch_address_with_invalid_watch_size(self): """Exercise SBTarget.WatchAddress() API but pass an invalid watch_size.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target by the debugger. target = self.dbg.CreateTarget(exe) Index: lldb/test/API/qemu/TestQemuLaunch.py =================================================================== --- lldb/test/API/qemu/TestQemuLaunch.py +++ lldb/test/API/qemu/TestQemuLaunch.py @@ -45,7 +45,7 @@ def _create_target(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target using our platform error = lldb.SBError() @@ -78,7 +78,7 @@ def test_basic_launch(self): state = self._run_and_get_state() - self.assertEqual(state["program"], self.getBuildArtifact("a.out")) + self.assertEqual(state["program"], self.getTestExecutable()) self.assertEqual(state["args"], ["dump:" + self.getBuildArtifact("state.log")]) @@ -118,7 +118,7 @@ def test_stdio_redirect(self): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() # Create a target using our platform error = lldb.SBError() @@ -168,7 +168,7 @@ self.addTearDownHook(cleanup) state = self._run_and_get_state() - self.assertEqual(state["program"], self.getBuildArtifact("a.out")) + self.assertEqual(state["program"], self.getTestExecutable()) self.assertEqual(state["args"], ["dump:" + self.getBuildArtifact("state.log")]) @@ -247,7 +247,7 @@ self.runCmd("settings set target.arg0 ARG0") state = self._run_and_get_state(target) - self.assertEqual(state["program"], self.getBuildArtifact("a.out")) + self.assertEqual(state["program"], self.getTestExecutable()) self.assertEqual(state["0"], "ARG0") def test_sysroot(self): Index: lldb/test/API/repl/clang/TestClangREPL.py =================================================================== --- lldb/test/API/repl/clang/TestClangREPL.py +++ lldb/test/API/repl/clang/TestClangREPL.py @@ -29,7 +29,7 @@ self.build() self.current_repl_line_number = 1 - self.launch(executable=self.getBuildArtifact("a.out"), dimensions=(100,500)) + self.launch(executable=self.getTestExecutable(), dimensions=(100,500)) # Try launching the REPL before we have a running target. self.expect("expression --repl -l c --", substrs=["REPL requires a running target process."]) Index: lldb/test/API/source-manager/TestSourceManager.py =================================================================== --- lldb/test/API/source-manager/TestSourceManager.py +++ lldb/test/API/source-manager/TestSourceManager.py @@ -50,7 +50,7 @@ def do_display_source_python_api(self, use_color, needle_regex, highlight_source=False): self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) target = self.dbg.CreateTarget(exe) @@ -137,7 +137,7 @@ def test_move_and_then_display_source(self): """Test that target.source-map settings work by moving main.c to hidden/main.c.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) # Move main.c to hidden/main.c. @@ -171,7 +171,7 @@ def test_modify_source_file_while_debugging(self): """Modify a source file while debugging the executable.""" self.build() - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( @@ -250,7 +250,7 @@ self.runCmd("settings set target.source-map %s %s" % (builddir_real, hidden_real)) - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() main = os.path.join(builddir_real, "hidden", "main-copy.c") self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) Index: lldb/test/API/symbol_ondemand/breakpoint_language/TestBreakpointLanguageOnDemand.py =================================================================== --- lldb/test/API/symbol_ondemand/breakpoint_language/TestBreakpointLanguageOnDemand.py +++ lldb/test/API/symbol_ondemand/breakpoint_language/TestBreakpointLanguageOnDemand.py @@ -31,7 +31,7 @@ self.runCmd("settings set symbols.load-on-demand true") # Create a target by the debugger. - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() 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 @@ self.runCmd("settings set symbols.load-on-demand true") # Create a target by the debugger. - exe = self.getBuildArtifact("a.out") + exe = self.getTestExecutable() error = lldb.SBError() # Don't read in dependencies so we don't come across false matches that # add unwanted breakpoint hits. Index: lldb/test/API/symbol_ondemand/breakpoint_source_regex/TestSourceTextRegexBreakpoint.py =================================================================== --- lldb/test/API/symbol_ondemand/breakpoint_source_regex/TestSourceTextRegexBreakpoint.py +++ lldb/test/API/symbol_ondemand/breakpoint_source_regex/TestSourceTextRegexBreakpoint.py @@ -20,7 +20,7 @@ # Load symbols on-demand self.runCmd("settings set symbols.load-on-demand true") - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_source_regexp( self, "Set break point at this line.") Index: lldb/test/API/symbol_ondemand/shared_library/TestSharedLibOnDemand.py =================================================================== --- lldb/test/API/symbol_ondemand/shared_library/TestSharedLibOnDemand.py +++ lldb/test/API/symbol_ondemand/shared_library/TestSharedLibOnDemand.py @@ -26,7 +26,7 @@ self.runCmd("settings set symbols.load-on-demand true") # Create a target by the debugger. - self.target = self.dbg.CreateTarget(self.getBuildArtifact("a.out")) + self.target = self.dbg.CreateTarget(self.getTestExecutable()) self.assertTrue(self.target, VALID_TARGET) # Register our shared libraries for remote targets so they get Index: lldb/test/API/tools/lldb-server/TestLldbGdbServer.py =================================================================== --- lldb/test/API/tools/lldb-server/TestLldbGdbServer.py +++ lldb/test/API/tools/lldb-server/TestLldbGdbServer.py @@ -1213,7 +1213,7 @@ @add_test_categories(["llgs"]) def test_launch_via_A(self): self.build() - exe_path = self.getBuildArtifact("a.out") + exe_path = self.getTestExecutable() args = [exe_path, "stderr:arg1", "stderr:arg2", "stderr:arg3"] hex_args = [binascii.b2a_hex(x.encode()).decode() for x in args] @@ -1238,7 +1238,7 @@ @add_test_categories(["llgs"]) def test_launch_via_vRun(self): self.build() - exe_path = self.getBuildArtifact("a.out") + exe_path = self.getTestExecutable() args = [exe_path, "stderr:arg1", "stderr:arg2", "stderr:arg3"] hex_args = [binascii.b2a_hex(x.encode()).decode() for x in args] @@ -1259,7 +1259,7 @@ @add_test_categories(["llgs"]) def test_launch_via_vRun_no_args(self): self.build() - exe_path = self.getBuildArtifact("a.out") + exe_path = self.getTestExecutable() hex_path = binascii.b2a_hex(exe_path.encode()).decode() server = self.connect_to_debug_monitor() @@ -1278,7 +1278,7 @@ @add_test_categories(["llgs"]) def test_QEnvironment(self): self.build() - exe_path = self.getBuildArtifact("a.out") + exe_path = self.getTestExecutable() env = {"FOO": "test", "BAR": "a=z"} args = [exe_path, "print-env:FOO", "print-env:BAR"] hex_args = [binascii.b2a_hex(x.encode()).decode() for x in args] @@ -1306,7 +1306,7 @@ @add_test_categories(["llgs"]) def test_QEnvironmentHexEncoded(self): self.build() - exe_path = self.getBuildArtifact("a.out") + exe_path = self.getTestExecutable() env = {"FOO": "test", "BAR": "a=z", "BAZ": "a*}#z"} args = [exe_path, "print-env:FOO", "print-env:BAR", "print-env:BAZ"] hex_args = [binascii.b2a_hex(x.encode()).decode() for x in args] Index: lldb/test/API/tools/lldb-vscode/attach/TestVSCode_attach.py =================================================================== --- lldb/test/API/tools/lldb-vscode/attach/TestVSCode_attach.py +++ lldb/test/API/tools/lldb-vscode/attach/TestVSCode_attach.py @@ -51,7 +51,7 @@ Tests attaching to a process by process ID. ''' self.build_and_create_debug_adaptor() - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() self.process = subprocess.Popen([program], stdin=subprocess.PIPE, stdout=subprocess.PIPE, @@ -67,7 +67,7 @@ Tests attaching to a process by process name. ''' self.build_and_create_debug_adaptor() - orig_program = self.getBuildArtifact("a.out") + orig_program = self.getTestExecutable() # Since we are going to attach by process name, we need a unique # process name that has minimal chance to match a process that is # already running. To do this we use tempfile.mktemp() to give us a @@ -106,7 +106,7 @@ ones. ''' self.build_and_create_debug_adaptor() - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() self.spawn_thread = threading.Thread(target=spawn_and_wait, args=(program, 1.0,)) self.spawn_thread.start() @@ -139,7 +139,7 @@ the debugger session terminates. ''' self.build_and_create_debug_adaptor() - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() # Here we just create a target and launch the process as a way to test # if we are able to use attach commands to create any kind of a target # and use it for debugging @@ -208,7 +208,7 @@ attach, are run when the debugger is disconnected. ''' self.build_and_create_debug_adaptor() - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() # Here we just create a target and launch the process as a way to test # if we are able to use attach commands to create any kind of a target # and use it for debugging Index: lldb/test/API/tools/lldb-vscode/breakpoint-events/TestVSCode_breakpointEvents.py =================================================================== --- lldb/test/API/tools/lldb-vscode/breakpoint-events/TestVSCode_breakpointEvents.py +++ lldb/test/API/tools/lldb-vscode/breakpoint-events/TestVSCode_breakpointEvents.py @@ -47,7 +47,7 @@ # Visual Studio Code Debug Adaptors have no way to specify the file # without launching or attaching to a process, so we must start a # process in order to be able to set breakpoints. - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() # Set a breakpoint after creating the target by running a command line # command. It will eventually resolve and cause a breakpoint changed Index: lldb/test/API/tools/lldb-vscode/breakpoint/TestVSCode_setBreakpoints.py =================================================================== --- lldb/test/API/tools/lldb-vscode/breakpoint/TestVSCode_setBreakpoints.py +++ lldb/test/API/tools/lldb-vscode/breakpoint/TestVSCode_setBreakpoints.py @@ -54,7 +54,7 @@ main_line = line_number('main.cpp', 'break 12') other_line = line_number('other.c', 'break other') - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() source_map = [ [source_folder, new_main_folder], [source_folder, new_other_folder], @@ -126,7 +126,7 @@ # Visual Studio Code Debug Adaptors have no way to specify the file # without launching or attaching to a process, so we must start a # process in order to be able to set breakpoints. - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() self.build_and_launch(program) # Set 3 breakpoints and verify that they got set correctly @@ -247,7 +247,7 @@ # Visual Studio Code Debug Adaptors have no way to specify the file # without launching or attaching to a process, so we must start a # process in order to be able to set breakpoints. - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() self.build_and_launch(program) # Set one breakpoint and verify that it got set correctly. @@ -284,7 +284,7 @@ breakpoint, like 'conditions' and 'hitCondition' settings.''' loop_line = line_number('main.cpp', '// break loop') - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() self.build_and_launch(program) # Set a breakpoint at the loop line with no condition and no # hitCondition Index: lldb/test/API/tools/lldb-vscode/breakpoint/TestVSCode_setExceptionBreakpoints.py =================================================================== --- lldb/test/API/tools/lldb-vscode/breakpoint/TestVSCode_setExceptionBreakpoints.py +++ lldb/test/API/tools/lldb-vscode/breakpoint/TestVSCode_setExceptionBreakpoints.py @@ -35,7 +35,7 @@ # Visual Studio Code Debug Adaptors have no way to specify the file # without launching or attaching to a process, so we must start a # process in order to be able to set breakpoints. - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() self.build_and_launch(program) filters = ['cpp_throw', 'cpp_catch'] Index: lldb/test/API/tools/lldb-vscode/breakpoint/TestVSCode_setFunctionBreakpoints.py =================================================================== --- lldb/test/API/tools/lldb-vscode/breakpoint/TestVSCode_setFunctionBreakpoints.py +++ lldb/test/API/tools/lldb-vscode/breakpoint/TestVSCode_setFunctionBreakpoints.py @@ -34,7 +34,7 @@ # Visual Studio Code Debug Adaptors have no way to specify the file # without launching or attaching to a process, so we must start a # process in order to be able to set breakpoints. - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() self.build_and_launch(program) bp_id_12 = None functions = ['twelve'] @@ -113,7 +113,7 @@ '''Tests hitting breakpoints and the functionality of a single breakpoint, like 'conditions' and 'hitCondition' settings.''' - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() self.build_and_launch(program) # Set a breakpoint on "twelve" with no condition and no hitCondition functions = ['twelve'] Index: lldb/test/API/tools/lldb-vscode/completions/TestVSCode_completions.py =================================================================== --- lldb/test/API/tools/lldb-vscode/completions/TestVSCode_completions.py +++ lldb/test/API/tools/lldb-vscode/completions/TestVSCode_completions.py @@ -28,7 +28,7 @@ """ Tests the completion request at different breakpoints """ - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() self.build_and_launch(program) source = "main.cpp" breakpoint1_line = line_number(source, "// breakpoint 1") Index: lldb/test/API/tools/lldb-vscode/console/TestVSCode_console.py =================================================================== --- lldb/test/API/tools/lldb-vscode/console/TestVSCode_console.py +++ lldb/test/API/tools/lldb-vscode/console/TestVSCode_console.py @@ -40,7 +40,7 @@ evaluated and the lldb commands that start with the backtick character. ''' - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() self.build_and_launch(program) source = 'main.cpp' breakpoint1_line = line_number(source, '// breakpoint 1') Index: lldb/test/API/tools/lldb-vscode/console/TestVSCode_redirection_to_console.py =================================================================== --- lldb/test/API/tools/lldb-vscode/console/TestVSCode_redirection_to_console.py +++ lldb/test/API/tools/lldb-vscode/console/TestVSCode_redirection_to_console.py @@ -20,7 +20,7 @@ Exception: unexpected malformed message from lldb-vscode """ - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() self.build_and_launch( program, lldbVSCodeEnv={"LLDB_VSCODE_TEST_STDOUT_STDERR_REDIRECTION": ""}) Index: lldb/test/API/tools/lldb-vscode/correct-thread/TestVSCode_correct_thread.py =================================================================== --- lldb/test/API/tools/lldb-vscode/correct-thread/TestVSCode_correct_thread.py +++ lldb/test/API/tools/lldb-vscode/correct-thread/TestVSCode_correct_thread.py @@ -25,7 +25,7 @@ In this case, the selected thread should be the thread that just hit the breakpoint, and not the first thread in the list. ''' - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() self.build_and_launch(program) source = 'main.c' breakpoint_line = line_number(source, '// break here') Index: lldb/test/API/tools/lldb-vscode/disconnect/TestVSCode_disconnect.py =================================================================== --- lldb/test/API/tools/lldb-vscode/disconnect/TestVSCode_disconnect.py +++ lldb/test/API/tools/lldb-vscode/disconnect/TestVSCode_disconnect.py @@ -35,7 +35,7 @@ before the file is created, which terminates the process and thus the file is not created. """ - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() self.build_and_launch(program, disconnectAutomatically=False) # We set a breakpoint right before the side effect file is created @@ -59,7 +59,7 @@ the file is created anyway. """ self.build_and_create_debug_adaptor() - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() # Use a file as a synchronization point between test and inferior. sync_file_path = lldbutil.append_to_process_working_directory(self, Index: lldb/test/API/tools/lldb-vscode/evaluate/TestVSCode_evaluate.py =================================================================== --- lldb/test/API/tools/lldb-vscode/evaluate/TestVSCode_evaluate.py +++ lldb/test/API/tools/lldb-vscode/evaluate/TestVSCode_evaluate.py @@ -31,7 +31,7 @@ Tests the evaluate expression request at different breakpoints """ self.context = context - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() self.build_and_launch(program) source = "main.cpp" self.set_source_breakpoints( Index: lldb/test/API/tools/lldb-vscode/launch/TestVSCode_launch.py =================================================================== --- lldb/test/API/tools/lldb-vscode/launch/TestVSCode_launch.py +++ lldb/test/API/tools/lldb-vscode/launch/TestVSCode_launch.py @@ -25,7 +25,7 @@ Tests the default launch of a simple program. No arguments, environment, or anything else is specified. ''' - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() self.build_and_launch(program) self.continue_to_exit() # Now get the STDOUT and verify our program argument is correct @@ -68,7 +68,7 @@ Tests the default launch of a simple program that stops at the entry point instead of continuing. ''' - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() self.build_and_launch(program, stopOnEntry=True) self.set_function_breakpoints(['main']) stopped_events = self.continue_to_next_stop() @@ -88,7 +88,7 @@ Tests the default launch of a simple program with a current working directory. ''' - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() program_parent_dir = os.path.realpath( os.path.dirname(os.path.dirname(program))) self.build_and_launch(program, @@ -116,7 +116,7 @@ Tests the "debuggerRoot" will change the working directory of the lldb-vscode debug adaptor. ''' - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() program_parent_dir = os.path.realpath( os.path.dirname(os.path.dirname(program))) commands = ['platform shell echo cwd = $PWD'] @@ -144,7 +144,7 @@ ''' Tests the "sourcePath" will set the target.source-map. ''' - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() program_dir = os.path.dirname(program) self.build_and_launch(program, sourcePath=program_dir) @@ -170,7 +170,7 @@ ''' Tests the default launch of a simple program with STDIO disabled. ''' - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() self.build_and_launch(program, disableSTDIO=True) self.continue_to_exit() @@ -189,7 +189,7 @@ Tests the default launch of a simple program with shell expansion enabled. ''' - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() program_dir = os.path.dirname(program) glob = os.path.join(program_dir, '*.out') self.build_and_launch(program, args=[glob], shellExpandArguments=True) @@ -213,7 +213,7 @@ Tests the default launch of a simple program with shell expansion disabled. ''' - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() program_dir = os.path.dirname(program) glob = os.path.join(program_dir, '*.out') self.build_and_launch(program, @@ -238,7 +238,7 @@ ''' Tests launch of a simple program with arguments ''' - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() args = ["one", "with space", "'with single quotes'", '"with double quotes"'] self.build_and_launch(program, @@ -264,7 +264,7 @@ ''' Tests launch of a simple program with environment variables ''' - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() env = ["NO_VALUE", "WITH_VALUE=BAR", "EMPTY_VALUE=", "SPACE=Hello World"] self.build_and_launch(program, @@ -311,7 +311,7 @@ "terminateCommands" are a list of LLDB commands that get executed when the debugger session terminates. ''' - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() initCommands = ['target list', 'platform list'] preRunCommands = ['image list a.out', 'image dump sections a.out'] postRunCommands = ['help trace', 'help process trace'] @@ -377,7 +377,7 @@ Tests the "launchCommands" with extra launching settings ''' self.build_and_create_debug_adaptor() - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() source = 'main.c' first_line = line_number(source, '// breakpoint 1') @@ -444,7 +444,7 @@ launch, are run when the debugger is disconnected. ''' self.build_and_create_debug_adaptor() - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() terminateCommands = ['expr 4+2'] self.launch(program=program, Index: lldb/test/API/tools/lldb-vscode/module/TestVSCode_module.py =================================================================== --- lldb/test/API/tools/lldb-vscode/module/TestVSCode_module.py +++ lldb/test/API/tools/lldb-vscode/module/TestVSCode_module.py @@ -80,7 +80,7 @@ @skipIfRemote @expectedFailureAll(oslist=["freebsd"], bugnumber="llvm.org/pr49418") def test_compile_units(self): - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() self.build_and_launch(program) source = "main.cpp" main_source_path = self.getSourcePath(source) Index: lldb/test/API/tools/lldb-vscode/optimized/TestVSCode_optimized.py =================================================================== --- lldb/test/API/tools/lldb-vscode/optimized/TestVSCode_optimized.py +++ lldb/test/API/tools/lldb-vscode/optimized/TestVSCode_optimized.py @@ -20,7 +20,7 @@ def test_stack_frame_name(self): ''' Test optimized frame has special name suffix. ''' - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() self.build_and_launch(program) source = 'main.cpp' breakpoint_line = line_number(source, '// breakpoint 1') @@ -39,7 +39,7 @@ def test_optimized_variable(self): ''' Test optimized variable value contains error. ''' - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() self.build_and_launch(program) source = 'main.cpp' breakpoint_line = line_number(source, '// breakpoint 2') Index: lldb/test/API/tools/lldb-vscode/runInTerminal/TestVSCode_runInTerminal.py =================================================================== --- lldb/test/API/tools/lldb-vscode/runInTerminal/TestVSCode_runInTerminal.py +++ lldb/test/API/tools/lldb-vscode/runInTerminal/TestVSCode_runInTerminal.py @@ -57,7 +57,7 @@ Tests the "runInTerminal" reverse request. It makes sure that the IDE can launch the inferior with the correct environment variables and arguments. ''' - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() source = 'main.c' self.build_and_launch( program, stopOnEntry=True, runInTerminal=True, args=["foobar"], Index: lldb/test/API/tools/lldb-vscode/stackTrace/TestVSCode_stackTrace.py =================================================================== --- lldb/test/API/tools/lldb-vscode/stackTrace/TestVSCode_stackTrace.py +++ lldb/test/API/tools/lldb-vscode/stackTrace/TestVSCode_stackTrace.py @@ -57,7 +57,7 @@ ''' Tests the 'stackTrace' packet and all its variants. ''' - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() self.build_and_launch(program) source = 'main.c' self.source_path = os.path.join(os.getcwd(), source) Index: lldb/test/API/tools/lldb-vscode/step/TestVSCode_step.py =================================================================== --- lldb/test/API/tools/lldb-vscode/step/TestVSCode_step.py +++ lldb/test/API/tools/lldb-vscode/step/TestVSCode_step.py @@ -21,7 +21,7 @@ ''' Tests the stepping in/out/over in threads. ''' - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() self.build_and_launch(program) source = 'main.cpp' # source_path = os.path.join(os.getcwd(), source) Index: lldb/test/API/tools/lldb-vscode/stop-hooks/TestVSCode_stop_hooks.py =================================================================== --- lldb/test/API/tools/lldb-vscode/stop-hooks/TestVSCode_stop_hooks.py +++ lldb/test/API/tools/lldb-vscode/stop-hooks/TestVSCode_stop_hooks.py @@ -18,7 +18,7 @@ Test that there is no race condition between lldb-vscode and stop hooks executor ''' - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() preRunCommands = ['target stop-hook add -o help'] self.build_and_launch(program, stopOnEntry=True, preRunCommands=preRunCommands) Index: lldb/test/API/tools/lldb-vscode/variables/TestVSCode_variables.py =================================================================== --- lldb/test/API/tools/lldb-vscode/variables/TestVSCode_variables.py +++ lldb/test/API/tools/lldb-vscode/variables/TestVSCode_variables.py @@ -89,7 +89,7 @@ Tests the "scopes", "variables", "setVariable", and "evaluate" packets. ''' - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() self.build_and_launch(program) source = 'main.cpp' breakpoint1_line = line_number(source, '// breakpoint 1') @@ -299,7 +299,7 @@ Tests the evaluated expression expands successfully after "scopes" packets and permanent expressions persist. """ - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() self.build_and_launch(program) source = "main.cpp" breakpoint1_line = line_number(source, "// breakpoint 1") @@ -441,7 +441,7 @@ providers have "indexedVariables" key/value pairs. This helps the IDE not to fetch too many children all at once. """ - program = self.getBuildArtifact("a.out") + program = self.getTestExecutable() self.build_and_launch(program) source = "main.cpp" breakpoint1_line = line_number(source, "// breakpoint 4") Index: lldb/test/API/types/TestRecursiveTypes.py =================================================================== --- lldb/test/API/types/TestRecursiveTypes.py +++ lldb/test/API/types/TestRecursiveTypes.py @@ -39,7 +39,7 @@ self.print_struct() def print_struct(self): - self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) + self.runCmd("file " + self.getTestExecutable(), CURRENT_EXECUTABLE_SET) lldbutil.run_break_set_by_file_and_line( self,