[lldb] Remove support for replaying the test suite from a reproducer

This patch removes the infrastructure to replay the test suite from a
reproducer, as well as the modifications made to the individual tests.
This commit is contained in:
Jonas Devlieghere 2021-09-29 22:32:21 -07:00
parent 244aa7f735
commit b505ed9d31
98 changed files with 57 additions and 397 deletions

View File

@ -117,10 +117,6 @@ clang_module_cache_dir = None
# Test results handling globals
test_result = None
# Reproducers
capture_path = None
replay_path = None
# The names of all tests. Used to assert we don't have two tests with the
# same base name.
all_tests = set()
@ -158,18 +154,3 @@ def get_yaml2obj_path():
"""
if yaml2obj and os.path.lexists(yaml2obj):
return yaml2obj
def is_reproducer_replay():
"""
Returns true when dotest is being replayed from a reproducer. Never use
this method to guard SB API calls as it will cause a divergence between
capture and replay.
"""
return replay_path is not None
def is_reproducer():
"""
Returns true when dotest is capturing a reproducer or is being replayed
from a reproducer. Use this method to guard SB API calls.
"""
return capture_path or replay_path

View File

@ -908,9 +908,3 @@ def skipUnlessFeature(feature):
except subprocess.CalledProcessError:
return "%s is not supported on this system." % feature
return skipTestIfFn(is_feature_enabled)
def skipIfReproducer(func):
"""Skip this test if the environment is set up to run LLDB with reproducers."""
return unittest2.skipIf(
configuration.capture_path or configuration.replay_path,
"reproducers unsupported")(func)

View File

@ -393,16 +393,6 @@ def parseOptionsAndInitTestdirs():
if do_help:
usage(parser)
# Reproducer arguments
if args.capture_path and args.replay_path:
logging.error('Cannot specify both a capture and a replay path.')
sys.exit(-1)
if args.capture_path:
configuration.capture_path = args.capture_path
if args.replay_path:
configuration.replay_path = args.replay_path
if args.lldb_platform_name:
configuration.lldb_platform_name = args.lldb_platform_name
if args.lldb_platform_url:
@ -888,19 +878,8 @@ def run_suite():
setupSysPath()
import lldbconfig
if configuration.capture_path or configuration.replay_path:
lldbconfig.INITIALIZE = False
import lldb
if configuration.capture_path:
lldb.SBReproducer.Capture(configuration.capture_path)
lldb.SBReproducer.SetAutoGenerate(True)
elif configuration.replay_path:
lldb.SBReproducer.PassiveReplay(configuration.replay_path)
if not lldbconfig.INITIALIZE:
lldb.SBDebugger.Initialize()
lldb.SBDebugger.Initialize()
# Use host platform by default.
lldb.selected_platform = lldb.SBPlatform.GetHostPlatform()

View File

@ -189,17 +189,6 @@ def create_parser():
metavar='platform-working-dir',
help='The directory to use on the remote platform.')
# Reproducer options
group = parser.add_argument_group('Reproducer options')
group.add_argument(
'--capture-path',
metavar='reproducer path',
help='The reproducer capture path')
group.add_argument(
'--replay-path',
metavar='reproducer path',
help='The reproducer replay path')
# Test-suite behaviour
group = parser.add_argument_group('Runtime behaviour options')
X('-d', 'Suspend the process after launch to wait indefinitely for a debugger to attach')

View File

@ -746,14 +746,6 @@ class Base(unittest2.TestCase):
return os.path.join(configuration.test_build_dir, self.mydir,
self.getBuildDirBasename())
def getReproducerDir(self):
"""Return the full path to the reproducer if enabled."""
if configuration.capture_path:
return configuration.capture_path
if configuration.replay_path:
return configuration.replay_path
return None
def makeBuildDir(self):
"""Create the test-specific working directory, deleting any previous
contents."""
@ -770,16 +762,6 @@ class Base(unittest2.TestCase):
"""Return absolute path to a file in the test's source directory."""
return os.path.join(self.getSourceDir(), name)
def getReproducerArtifact(self, name):
lldbutil.mkdir_p(self.getReproducerDir())
return os.path.join(self.getReproducerDir(), name)
def getReproducerRemappedPath(self, path):
assert configuration.replay_path
assert os.path.isabs(path)
path = os.path.relpath(path, '/')
return os.path.join(configuration.replay_path, 'root', path)
@classmethod
def setUpCommands(cls):
commands = [
@ -1097,11 +1079,8 @@ class Base(unittest2.TestCase):
# the shared module cache.
lldb.SBModule.GarbageCollectAllocatedModules()
# Modules are not orphaned during reproducer replay because they're
# leaked on purpose.
if not configuration.is_reproducer():
# Assert that the global module cache is empty.
self.assertEqual(lldb.SBModule.GetNumberAllocatedModules(), 0)
# Assert that the global module cache is empty.
self.assertEqual(lldb.SBModule.GetNumberAllocatedModules(), 0)
# =========================================================
@ -2101,9 +2080,8 @@ class TestBase(Base):
for target in targets:
self.dbg.DeleteTarget(target)
if not configuration.is_reproducer():
# Assert that all targets are deleted.
self.assertEqual(self.dbg.GetNumTargets(), 0)
# Assert that all targets are deleted.
self.assertEqual(self.dbg.GetNumTargets(), 0)
# Do this last, to make sure it's in reverse order from how we setup.
Base.tearDown(self)

View File

@ -25,9 +25,6 @@ class APILogTestCase(TestBase):
self.dbg.GetScriptingLanguage(None)
target = self.dbg.CreateTarget(None)
if configuration.is_reproducer_replay():
logfile = self.getReproducerRemappedPath(logfile)
self.assertTrue(os.path.isfile(logfile))
with open(logfile, 'r') as f:
log = f.read()

View File

@ -14,7 +14,6 @@ class CmdPythonTestCase(TestBase):
mydir = TestBase.compute_mydir(__file__)
NO_DEBUG_INFO_TESTCASE = True
@skipIfReproducer # FIXME: Unexpected packet during (active) replay
def test(self):
self.build()
self.pycmd_tests()

View File

@ -14,7 +14,6 @@ class ExprSyscallTestCase(TestBase):
oslist=["windows"],
bugnumber="llvm.org/pr21765, getpid() does not exist on Windows")
@expectedFailureNetBSD
@skipIfReproducer
def test_setpgid(self):
self.build()
self.expr_syscall()

View File

@ -17,7 +17,6 @@ class Issue11581TestCase(TestBase):
mydir = TestBase.compute_mydir(__file__)
@expectedFailureAll(oslist=["windows"], bugnumber="llvm.org/pr24778")
@skipIfReproducer # FIXME: Unexpected packet during (active) replay
def test_11581_commands(self):
# This is the function to remove the custom commands in order to have a
# clean slate for the next test case.

View File

@ -16,7 +16,6 @@ class ExprDoesntDeadlockTestCase(TestBase):
mydir = TestBase.compute_mydir(__file__)
@add_test_categories(["basic_process"])
@skipIfReproducer # Timeouts are not currently modeled.
def test_with_run_command(self):
"""Test that expr will time out and allow other threads to run if it blocks."""
self.build()

View File

@ -26,7 +26,6 @@ class ExprCommandWithTimeoutsTestCase(TestBase):
oslist=[
"windows"],
bugnumber="llvm.org/pr21765")
@skipIfReproducer # Timeouts are not currently modeled.
def test(self):
"""Test calling std::String member function."""
self.build()

View File

@ -51,7 +51,6 @@ class UnwindFromExpressionTest(TestBase):
@add_test_categories(['pyapi'])
@expectedFlakeyNetBSD
@skipIfReproducer # FIXME: Unexpected packet during (passive) replay
def test_unwind_expression(self):
"""Test unwinding from an expression."""
self.build_and_run_to_bkpt()

View File

@ -20,8 +20,6 @@ class LogTestCase(TestBase):
super(LogTestCase, self).setUp()
self.log_file = self.getBuildArtifact("log-file.txt")
if configuration.is_reproducer_replay():
self.log_file = self.getReproducerRemappedPath(self.log_file)
def test_file_writing(self):
self.build()

View File

@ -29,9 +29,4 @@ class ProcessListTestCase(TestBase):
substrs = [str(popen.pid), "TestProcess arg1 --arg2 arg3"]
# Because LLDB isn't the one spawning the subprocess, the PID will be
# different during replay.
if configuration.is_reproducer_replay():
substrs.pop(0)
self.expect("platform process list -v", substrs=substrs)

View File

@ -20,7 +20,6 @@ class AttachResumeTestCase(TestBase):
@skipIfRemote
@expectedFailureNetBSD
@skipIfWindows # llvm.org/pr24778, llvm.org/pr21753
@skipIfReproducer # FIXME: Unexpected packet during (active) replay
def test_attach_continue_interrupt_detach(self):
"""Test attach/continue/interrupt/detach"""
self.build()

View File

@ -60,7 +60,6 @@ class ProcessAttachTestCase(TestBase):
self.assertTrue(process, PROCESS_IS_VALID)
self.assertTrue(process.GetState(), lldb.eStateRunning)
@skipIfReproducer # FIXME: Unexpected packet during (active) replay
@skipIfWindows # This is flakey on Windows AND when it fails, it hangs: llvm.org/pr48806
def test_attach_to_process_from_different_dir_by_id(self):
"""Test attach by process id"""

View File

@ -21,7 +21,6 @@ class AttachDeniedTestCase(TestBase):
@skipIfWindows
@skipIfiOSSimulator
@skipIfDarwinEmbedded # ptrace(ATTACH_REQUEST...) won't work on ios/tvos/etc
@skipIfReproducer
def test_attach_to_process_by_id_denied(self):
"""Test attach by process id denied"""
self.build()

View File

@ -29,7 +29,6 @@ class ProcessLaunchTestCase(TestBase):
TestBase.tearDown(self)
@skipIfRemote
@skipIfReproducer
def test_io(self):
"""Test that process launch I/O redirection flags work properly."""
self.build()
@ -85,7 +84,6 @@ class ProcessLaunchTestCase(TestBase):
@skipIfRemote
@expectedFailureAll(oslist=["freebsd", "linux"], bugnumber="llvm.org/pr20265")
@expectedFailureNetBSD
@skipIfReproducer
def test_set_working_dir_nonexisting(self):
"""Test that '-w dir' fails to set the working dir when running the inferior with a dir which doesn't exist."""
d = {'CXX_SOURCES': 'print_cwd.cpp'}
@ -113,7 +111,6 @@ class ProcessLaunchTestCase(TestBase):
invalid_dir_path])
@skipIfRemote
@skipIfReproducer
def test_set_working_dir_existing(self):
"""Test that '-w dir' sets the working dir when running the inferior."""
d = {'CXX_SOURCES': 'print_cwd.cpp'}
@ -173,7 +170,6 @@ class ProcessLaunchTestCase(TestBase):
if not success:
self.fail(err_msg)
@skipIfReproducer
def test_environment_with_special_char(self):
"""Test that environment variables containing '*' and '}' are handled correctly by the inferior."""
source = 'print_env.cpp'

View File

@ -24,7 +24,6 @@ class SessionSaveTestCase(TestBase):
@skipIfWindows
@skipIfReproducer
@no_debug_info_test
def test_session_save(self):
raw = ""
@ -92,7 +91,6 @@ class SessionSaveTestCase(TestBase):
self.assertIn(line, content)
@skipIfWindows
@skipIfReproducer
@no_debug_info_test
def test_session_save_on_quit(self):
raw = ""

View File

@ -239,12 +239,10 @@ class SettingsCommandTestCase(TestBase):
substrs=["5ah"])
@skipIfDarwinEmbedded # <rdar://problem/34446098> debugserver on ios etc can't write files
@skipIfReproducer
def test_run_args_and_env_vars(self):
self.do_test_run_args_and_env_vars(use_launchsimple=False)
@skipIfDarwinEmbedded # <rdar://problem/34446098> debugserver on ios etc can't write files
@skipIfReproducer
def test_launchsimple_args_and_env_vars(self):
self.do_test_run_args_and_env_vars(use_launchsimple=True)
@ -329,7 +327,6 @@ class SettingsCommandTestCase(TestBase):
"Environment variable 'MY_ENV_VAR' successfully passed."])
@skipIfRemote # it doesn't make sense to send host env to remote target
@skipIfReproducer
def test_pass_host_env_vars(self):
"""Test that the host env vars are passed to the launched process."""
self.build()
@ -426,7 +423,6 @@ class SettingsCommandTestCase(TestBase):
"The host environment variable 'MY_HOST_ENV_VAR2' successfully passed."])
@skipIfDarwinEmbedded # <rdar://problem/34446098> debugserver on ios etc can't write files
@skipIfReproducer
def test_set_error_output_path(self):
"""Test that setting target.error/output-path for the launched process works."""
self.build()

View File

@ -18,7 +18,6 @@ class SettingsCommandTestCase(TestBase):
"""Cleanup the test byproducts."""
cls.RemoveTempFile(SettingsCommandTestCase.output_file_name)
@skipIfReproducer # Reproducers don't know about output.txt
@no_debug_info_test
def test(self):
self.build()

View File

@ -358,7 +358,6 @@ class targetCommandTestCase(TestBase):
# Write only files don't seem to be supported on Windows.
@skipIfWindows
@skipIfReproducer # Cannot be captured in the VFS.
@no_debug_info_test
def test_target_create_unreadable_core_file(self):
tf = tempfile.NamedTemporaryFile()
@ -383,7 +382,6 @@ class targetCommandTestCase(TestBase):
# Write only files don't seem to be supported on Windows.
@skipIfWindows
@no_debug_info_test
@skipIfReproducer # Cannot be captured in the VFS.
def test_target_create_unreadable_sym_file(self):
tf = tempfile.NamedTemporaryFile()
os.chmod(tf.name, stat.S_IWRITE)

View File

@ -94,7 +94,6 @@ class WatchpointPythonCommandTestCase(TestBase):
self.expect("frame variable --show-globals cookie",
substrs=['(int32_t)', 'cookie = 777'])
@skipIfReproducer
def test_continue_in_watchpoint_command(self):
"""Test continue in a watchpoint command."""
self.build(dictionary=self.d)

View File

@ -17,14 +17,12 @@ class BreakpointCommandTestCase(TestBase):
mydir = TestBase.compute_mydir(__file__)
@expectedFailureAll(oslist=["windows"], bugnumber="llvm.org/pr24528")
@skipIfReproducer # side_effect bypasses reproducer
def test_breakpoint_command_sequence(self):
"""Test a sequence of breakpoint command add, list, and delete."""
self.build()
self.breakpoint_command_sequence()
@skipIf(oslist=["windows"], bugnumber="llvm.org/pr44431")
@skipIfReproducer # side_effect bypasses reproducer
def test_script_parameters(self):
"""Test a sequence of breakpoint command add, list, and delete."""
self.build()

View File

@ -18,13 +18,11 @@ class PythonBreakpointCommandSettingTestCase(TestBase):
NO_DEBUG_INFO_TESTCASE = True
@add_test_categories(['pyapi'])
@skipIfReproducer # side_effect bypasses reproducer
def test_step_out_python(self):
"""Test stepping out using a python breakpoint command."""
self.build()
self.do_set_python_command_from_python()
@skipIfReproducer # side_effect bypasses reproducer
def test_bkpt_cmd_bad_arguments(self):
"""Test what happens when pass structured data to a command:"""
self.build()

View File

@ -13,7 +13,6 @@ class BreakpointSetRestart(TestBase):
BREAKPOINT_TEXT = 'Set a breakpoint here'
@skipIfNetBSD
@skipIfReproducer
def test_breakpoint_set_restart(self):
self.build()

View File

@ -120,10 +120,6 @@ class TestObjCBreakpoints(TestBase):
self.check_category_breakpoints()
# Stop here for reproducers. They don't capture file system changes.
if configuration.is_reproducer():
return
if have_dsym:
shutil.rmtree(exe + ".dSYM")
self.assertEqual(subprocess.call(

View File

@ -16,7 +16,6 @@ class TestScriptedResolver(TestBase):
NO_DEBUG_INFO_TESTCASE = True
@expectedFailureAll(oslist=["windows"], bugnumber="llvm.org/pr24528")
@skipIfReproducer # FIXME: Unexpected packet during (active) replay
def test_scripted_resolver(self):
"""Use a scripted resolver to set a by symbol name breakpoint"""
self.build()

View File

@ -16,42 +16,36 @@ class BreakpointSerialization(TestBase):
NO_DEBUG_INFO_TESTCASE = True
@add_test_categories(['pyapi'])
@skipIfReproducer # side_effect bypasses reproducer
def test_resolvers(self):
"""Use Python APIs to test that we serialize resolvers."""
self.build()
self.setup_targets_and_cleanup()
self.do_check_resolvers()
@skipIfReproducer # side_effect bypasses reproducer
def test_filters(self):
"""Use Python APIs to test that we serialize search filters correctly."""
self.build()
self.setup_targets_and_cleanup()
self.do_check_filters()
@skipIfReproducer # side_effect bypasses reproducer
def test_options(self):
"""Use Python APIs to test that we serialize breakpoint options correctly."""
self.build()
self.setup_targets_and_cleanup()
self.do_check_options()
@skipIfReproducer # side_effect bypasses reproducer
def test_appending(self):
"""Use Python APIs to test that we serialize breakpoint options correctly."""
self.build()
self.setup_targets_and_cleanup()
self.do_check_appending()
@skipIfReproducer # side_effect bypasses reproducer
def test_name_filters(self):
"""Use python APIs to test that reading in by name works correctly."""
self.build()
self.setup_targets_and_cleanup()
self.do_check_names()
@skipIfReproducer # side_effect bypasses reproducer
def test_scripted_extra_args(self):
self.build()
self.setup_targets_and_cleanup()

View File

@ -51,7 +51,6 @@ class StepOverBreakpointsTestCase(TestBase):
self.thread = lldbutil.get_one_thread_stopped_at_breakpoint(self.process, self.breakpoint1)
self.assertIsNotNone(self.thread, "Didn't stop at breakpoint 1.")
@skipIfReproducer
def test_step_instruction(self):
# Count instructions between breakpoint_1 and breakpoint_4
contextList = self.target.FindFunctions('main', lldb.eFunctionNameTypeAuto)

View File

@ -131,7 +131,6 @@ class CommandLineCompletionTestCase(TestBase):
@skipIfRemote
@skipIfReproducer
def test_common_completion_process_pid_and_name(self):
# The LLDB process itself and the process already attached to are both
# ignored by the process discovery mechanism, thus we need a process known

View File

@ -26,7 +26,6 @@ class ConditionalBreakTestCase(TestBase):
self.build()
self.do_conditional_break()
@skipIfReproducer # FIXME: Unexpected packet during (active) replay
def test_with_command(self):
"""Simulate a user using lldb commands to break on c() if called from a()."""
self.build()

View File

@ -19,7 +19,6 @@ class TestDeletedExecutable(TestBase):
@expectedFailureAll(oslist=["linux"],
triple=no_match('aarch64-.*-android'))
# determining the architecture of the process fails
@skipIfReproducer # File synchronization is not supported during replay.
def test(self):
self.build()
exe = self.getBuildArtifact("a.out")

View File

@ -12,14 +12,12 @@ class TestGDBRemoteClient(GDBRemoteTestBase):
def readRegisters(self):
return '0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
@skipIfReproducer # Packet log is not populated during replay.
def test_connect(self):
"""Test connecting to a remote gdb server"""
target = self.createTarget("a.yaml")
process = self.connect(target)
self.assertPacketLogContains(["qProcessInfo", "qfThreadInfo"])
@skipIfReproducer # FIXME: Unexpected packet during (active) replay
def test_attach_fail(self):
error_msg = "mock-error-msg"
@ -69,7 +67,6 @@ class TestGDBRemoteClient(GDBRemoteTestBase):
None, 0, True, error)
self.assertEquals("'A' packet returned an error: 71", error.GetCString())
@skipIfReproducer # Packet log is not populated during replay.
def test_read_registers_using_g_packets(self):
"""Test reading registers using 'g' packets (default behavior)"""
self.dbg.HandleCommand(
@ -87,7 +84,6 @@ class TestGDBRemoteClient(GDBRemoteTestBase):
self.assertEquals(
0, len([p for p in self.server.responder.packetLog if p.startswith("p")]))
@skipIfReproducer # Packet log is not populated during replay.
def test_read_registers_using_p_packets(self):
"""Test reading registers using 'p' packets"""
self.dbg.HandleCommand(
@ -100,7 +96,6 @@ class TestGDBRemoteClient(GDBRemoteTestBase):
self.assertGreater(
len([p for p in self.server.responder.packetLog if p.startswith("p")]), 0)
@skipIfReproducer # Packet log is not populated during replay.
def test_write_registers_using_P_packets(self):
"""Test writing registers using 'P' packets (default behavior)"""
self.server.responder = self.gPacketResponder()
@ -113,7 +108,6 @@ class TestGDBRemoteClient(GDBRemoteTestBase):
self.assertGreater(
len([p for p in self.server.responder.packetLog if p.startswith("P")]), 0)
@skipIfReproducer # Packet log is not populated during replay.
def test_write_registers_using_G_packets(self):
"""Test writing registers using 'G' packets"""

View File

@ -19,7 +19,6 @@ class TestGDBRemoteLoad(GDBRemoteTestBase):
self.assertTrue(address.IsValid())
self.assertEqual(".data", address.GetSection().GetName())
@skipIfReproducer # Packet log is not populated during replay.
@expectedFailureAll(archs=["aarch64"], oslist=["freebsd"],
bugnumber="llvm.org/pr49414")
def test_ram_load(self):
@ -33,7 +32,6 @@ class TestGDBRemoteLoad(GDBRemoteTestBase):
])
@skipIfXmlSupportMissing
@skipIfReproducer # Packet log is not populated during replay.
@expectedFailureAll(archs=["aarch64"], oslist=["freebsd"],
bugnumber="llvm.org/pr49414")
def test_flash_load(self):

View File

@ -3,7 +3,6 @@ from lldbsuite.test.lldbtest import *
from lldbsuite.test.decorators import *
from gdbclientutils import *
@skipIfReproducer
class TestIOSSimulator(GDBRemoteTestBase):
"""
Test that an ios simulator process is recognized as such.

View File

@ -184,15 +184,13 @@ class TestJLink6Armv7RegisterDefinition(GDBRemoteTestBase):
err = msp_valobj.GetError()
self.assertTrue(err.Fail(), "lldb should not be able to fetch the msp register")
# Reproducers don't support SetData (yet) because it takes a void*.
if not configuration.is_reproducer():
val = b'\x11\x22\x33\x44'
error = lldb.SBError()
data = lldb.SBData()
data.SetData(error, val, lldb.eByteOrderBig, 4)
self.assertEqual(r1_valobj.SetData(data, error), True)
self.assertTrue(error.Success())
val = b'\x11\x22\x33\x44'
error = lldb.SBError()
data = lldb.SBData()
data.SetData(error, val, lldb.eByteOrderBig, 4)
self.assertEqual(r1_valobj.SetData(data, error), True)
self.assertTrue(error.Success())
r1_valobj = process.GetThreadAtIndex(0).GetFrameAtIndex(0).FindRegister("r1")
self.assertEqual(r1_valobj.GetValueAsUnsigned(), 0x11223344)
r1_valobj = process.GetThreadAtIndex(0).GetFrameAtIndex(0).FindRegister("r1")
self.assertEqual(r1_valobj.GetValueAsUnsigned(), 0x11223344)

View File

@ -20,7 +20,6 @@ class TestProcessConnect(GDBRemoteTestBase):
finally:
self.dbg.GetSelectedPlatform().DisconnectRemote()
@skipIfReproducer # Reproducer don't support async.
def test_gdb_remote_async(self):
"""Test the gdb-remote command in asynchronous mode"""
try:
@ -47,7 +46,6 @@ class TestProcessConnect(GDBRemoteTestBase):
self.dbg.GetSelectedPlatform().DisconnectRemote()
@skipIfWindows
@skipIfReproducer # Reproducer don't support async.
def test_process_connect_async(self):
"""Test the gdb-remote command in asynchronous mode"""
try:

View File

@ -8,7 +8,6 @@ from gdbclientutils import *
class TestRestartBug(GDBRemoteTestBase):
@expectedFailureAll(bugnumber="llvm.org/pr24530")
@skipIfReproducer # FIXME: Unexpected packet during (passive) replay
def test(self):
"""
Test auto-continue behavior when a process is interrupted to deliver

View File

@ -6,7 +6,6 @@ from gdbclientutils import *
class TestWriteMemory(GDBRemoteTestBase):
@skipIfReproducer # SBProcess::WriteMemory is not instrumented.
def test(self):
class MyResponder(MockGDBServerResponder):

View File

@ -16,7 +16,6 @@ class ChangedInferiorTestCase(TestBase):
@skipIf(hostoslist=["windows"])
@no_debug_info_test
@skipIfReproducer # VFS is a snapshot.
def test_inferior_crashing(self):
"""Test lldb reloads the inferior after it was changed during the session."""
self.build()

View File

@ -72,10 +72,9 @@ class JITLoaderGDBTestCase(TestBase):
self.assertEqual(process.GetState(), lldb.eStateExited)
self.assertEqual(process.GetExitStatus(), 0)
if not configuration.is_reproducer():
self.assertTrue(os.path.exists(logfile))
logcontent = open(logfile).read()
self.assertIn("SetJITBreakpoint setting JIT breakpoint", logcontent)
self.assertTrue(os.path.exists(logfile))
logcontent = open(logfile).read()
self.assertIn("SetJITBreakpoint setting JIT breakpoint", logcontent)
@skipIfWindows # This test fails on Windows during C code build
def test_jit_int_off(self):
@ -101,7 +100,6 @@ class JITLoaderGDBTestCase(TestBase):
self.assertEqual(process.GetState(), lldb.eStateExited)
self.assertEqual(process.GetExitStatus(), 0)
if not configuration.is_reproducer():
self.assertTrue(os.path.exists(logfile))
logcontent = open(logfile).read()
self.assertNotIn("SetJITBreakpoint setting JIT breakpoint", logcontent)
self.assertTrue(os.path.exists(logfile))
logcontent = open(logfile).read()
self.assertNotIn("SetJITBreakpoint setting JIT breakpoint", logcontent)

View File

@ -93,7 +93,6 @@ class LoadUnloadTestCase(TestBase):
@expectedFailureAll(oslist=["freebsd", "linux", "netbsd"])
@skipIfRemote
@skipIfWindows # Windows doesn't have dlopen and friends, dynamic libraries work differently
@skipIfReproducer # VFS is a snapshot.
def test_modules_search_paths(self):
"""Test target modules list after loading a different copy of the library libd.dylib, and verifies that it works with 'target modules search-paths add'."""
if self.platformIsDarwin():
@ -217,7 +216,6 @@ class LoadUnloadTestCase(TestBase):
self.setSvr4Support(True)
self.run_lldb_process_load_and_unload_commands()
@skipIfReproducer # FIXME: Unexpected packet during (passive) replay
def run_lldb_process_load_and_unload_commands(self):
"""Test that lldb process load/unload command work correctly."""
self.copy_shlibs_to_remote()

View File

@ -40,7 +40,6 @@ class LoadUsingPathsTestCase(TestBase):
@skipIfWindows # Windows doesn't have dlopen and friends, dynamic libraries work differently
@expectedFlakeyNetBSD
@expectedFailureAll(oslist=["linux"], archs=['arm'], bugnumber="llvm.org/pr45894")
@skipIfReproducer # FIXME: Unexpected packet during (passive) replay
def test_load_using_paths(self):
"""Test that we can load a module by providing a set of search paths."""
if self.platformIsDarwin():

View File

@ -150,8 +150,6 @@ class MemoryReadTestCase(TestBase):
golden_output = res.GetOutput()
memory_read_file = self.getBuildArtifact("memory-read-output")
if configuration.is_reproducer_replay():
memory_read_file = self.getReproducerRemappedPath(memory_read_file)
def check_file_content(expected):
with open(memory_read_file) as f:

View File

@ -33,41 +33,35 @@ class LinuxCoreTestCase(TestBase):
_ppc64le_regions = 2
@skipIfLLVMTargetMissing("AArch64")
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_aarch64(self):
"""Test that lldb can read the process information from an aarch64 linux core file."""
self.do_test("linux-aarch64", self._aarch64_pid,
self._aarch64_regions, "a.out")
@skipIfLLVMTargetMissing("X86")
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_i386(self):
"""Test that lldb can read the process information from an i386 linux core file."""
self.do_test("linux-i386", self._i386_pid, self._i386_regions, "a.out")
@skipIfLLVMTargetMissing("PowerPC")
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_ppc64le(self):
"""Test that lldb can read the process information from an ppc64le linux core file."""
self.do_test("linux-ppc64le", self._ppc64le_pid, self._ppc64le_regions,
"linux-ppc64le.ou")
@skipIfLLVMTargetMissing("X86")
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_x86_64(self):
"""Test that lldb can read the process information from an x86_64 linux core file."""
self.do_test("linux-x86_64", self._x86_64_pid, self._x86_64_regions,
"a.out")
@skipIfLLVMTargetMissing("SystemZ")
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_s390x(self):
"""Test that lldb can read the process information from an s390x linux core file."""
self.do_test("linux-s390x", self._s390x_pid, self._s390x_regions,
"a.out")
@skipIfLLVMTargetMissing("X86")
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_same_pid_running(self):
"""Test that we read the information from the core correctly even if we have a running
process with the same PID around"""
@ -95,7 +89,6 @@ class LinuxCoreTestCase(TestBase):
self._x86_64_regions, "a.out")
@skipIfLLVMTargetMissing("X86")
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_two_cores_same_pid(self):
"""Test that we handle the situation if we have two core files with the same PID
around"""
@ -127,7 +120,6 @@ class LinuxCoreTestCase(TestBase):
@skipIfLLVMTargetMissing("X86")
@skipIfWindows
@skipIfReproducer
def test_read_memory(self):
"""Test that we are able to read as many bytes as available"""
target = self.dbg.CreateTarget("linux-x86_64.out")
@ -192,7 +184,6 @@ class LinuxCoreTestCase(TestBase):
substrs=["{} = {}".format(regname, value)])
@skipIfLLVMTargetMissing("X86")
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_i386_sysroot(self):
"""Test that lldb can find the exe for an i386 linux core file using the sysroot."""
@ -219,7 +210,6 @@ class LinuxCoreTestCase(TestBase):
@skipIfLLVMTargetMissing("X86")
@skipIfWindows
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_x86_64_sysroot(self):
"""Test that sysroot has more priority then local filesystem."""

View File

@ -29,7 +29,6 @@ class MiniDumpNewTestCase(TestBase):
self.process = self.target.LoadCore(minidump_path)
return self.process
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def check_state(self):
with open(os.devnull) as devnul:
# sanitize test output
@ -345,7 +344,6 @@ class MiniDumpNewTestCase(TestBase):
"linux-x86_64_not_crashed.dmp",
self._linux_x86_64_not_crashed_pid)
@skipIfReproducer # VFS is a snapshot.
def do_change_pid_in_minidump(self, core, newcore, offset, oldpid, newpid):
""" This assumes that the minidump is breakpad generated on Linux -
meaning that the PID in the file will be an ascii string part of

View File

@ -12,7 +12,6 @@ from lldbsuite.test.lldbtest import *
from lldbsuite.test import lldbutil
@skipIfReproducer # Modules are not orphaned and it finds the module with the same UUID from test_partial_uuid_match.
class MiniDumpUUIDTestCase(TestBase):
mydir = TestBase.compute_mydir(__file__)

View File

@ -159,13 +159,11 @@ class NetBSD1LWPCoreTestCase(NetBSDCoreCommonTestCase):
self.check_backtrace(thread, filename, backtrace)
@skipIfLLVMTargetMissing("AArch64")
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_aarch64(self):
"""Test single-threaded aarch64 core dump."""
self.do_test("1lwp_SIGSEGV.aarch64", pid=8339, region_count=32)
@skipIfLLVMTargetMissing("X86")
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_amd64(self):
"""Test single-threaded amd64 core dump."""
self.do_test("1lwp_SIGSEGV.amd64", pid=693, region_count=21)
@ -191,13 +189,11 @@ class NetBSD2LWPT2CoreTestCase(NetBSDCoreCommonTestCase):
self.assertEqual(thread.GetStopReasonDataAtIndex(0), 0)
@skipIfLLVMTargetMissing("AArch64")
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_aarch64(self):
"""Test double-threaded aarch64 core dump where thread 2 is signalled."""
self.do_test("2lwp_t2_SIGSEGV.aarch64", pid=14142, region_count=31)
@skipIfLLVMTargetMissing("X86")
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_amd64(self):
"""Test double-threaded amd64 core dump where thread 2 is signalled."""
self.do_test("2lwp_t2_SIGSEGV.amd64", pid=622, region_count=24)
@ -223,13 +219,11 @@ class NetBSD2LWPProcessSigCoreTestCase(NetBSDCoreCommonTestCase):
self.assertEqual(thread.GetStopReasonDataAtIndex(0), signal.SIGSEGV)
@skipIfLLVMTargetMissing("AArch64")
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_aarch64(self):
"""Test double-threaded aarch64 core dump where process is signalled."""
self.do_test("2lwp_process_SIGSEGV.aarch64", pid=1403, region_count=30)
@skipIfLLVMTargetMissing("X86")
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_amd64(self):
"""Test double-threaded amd64 core dump where process is signalled."""
self.do_test("2lwp_process_SIGSEGV.amd64", pid=665, region_count=24)

View File

@ -24,7 +24,6 @@ class ChangeProcessGroupTestCase(TestBase):
@skipIfWindows # setpgid call does not exist on Windows
@expectedFailureAndroid("http://llvm.org/pr23762", api_levels=[16])
@expectedFailureNetBSD
@skipIfReproducer # File synchronization is not supported during replay.
@skipIftvOS # fork not available on tvOS.
@skipIfwatchOS # fork not available on watchOS.
def test_setpgid(self):

View File

@ -19,7 +19,6 @@ class ReproducerAttachTestCase(TestBase):
@skipIfWindows
@skipIfRemote
@skipIfiOSSimulator
@skipIfReproducer
def test_reproducer_attach(self):
"""Test thread creation after process attach."""
exe = '%s_%d' % (self.testMethodName, os.getpid())

View File

@ -19,7 +19,6 @@ class ReproducerFileSystemSensitivityTestCase(TestBase):
@skipIfWindows
@skipIfRemote
@skipIfiOSSimulator
@skipIfReproducer
def test_reproducer_attach(self):
# The reproducer output path. Note that this is on purpose a lower-case
# file name. See the case-sensitivity check below.

View File

@ -20,7 +20,6 @@ class SendSignalTestCase(TestBase):
@expectedFailureNetBSD(bugnumber='llvm.org/pr43959')
@skipIfWindows # Windows does not support signals
@skipIfReproducer # FIXME: Unexpected packet during (active) replay
def test_with_run_command(self):
"""Test that lldb command 'process signal SIGUSR1' sends a signal to the inferior process."""
self.build()

View File

@ -7,7 +7,6 @@ import lldbsuite.test.lldbutil as lldbutil
from lldbsuite.test.decorators import *
from lldbsuite.test.lldbtest import *
@skipIfReproducer # FIXME: Unexpected packet during (active) replay
class StepScriptedTestCase(TestBase):
mydir = TestBase.compute_mydir(__file__)

View File

@ -45,7 +45,6 @@ class TestExitDuringExpression(TestBase):
self.main_source_file = lldb.SBFileSpec("main.c")
self.build()
@skipIfReproducer # Timeouts are not currently modeled.
def exiting_expression_test(self, before_one_thread_timeout , unwind):
"""function_to_call sleeps for g_timeout microseconds, then calls pthread_exit.
This test calls function_to_call with an overall timeout of 500

View File

@ -8,7 +8,6 @@ class TestCase(TestBase):
mydir = TestBase.compute_mydir(__file__)
@no_debug_info_test
@skipIfReproducer
@skipIfWindows
def test_resize_no_editline(self):
""" Tests terminal resizing if the editline isn't used. """

View File

@ -44,8 +44,6 @@ class CModulesTestCase(TestBase):
# Enable logging of the imported AST.
log_file = self.getBuildArtifact("lldb-ast-log.txt")
if configuration.is_reproducer_replay():
log_file = self.getReproducerRemappedPath(log_file)
self.runCmd("log enable lldb ast -f '%s'" % log_file)
self.expect(

View File

@ -15,8 +15,6 @@ class CPPAcceleratorTableTestCase(TestBase):
self.build()
logfile = self.getBuildArtifact('dwarf.log')
if configuration.is_reproducer_replay():
logfile = self.getReproducerRemappedPath(logfile)
self.expect('log enable dwarf lookups -f' + logfile)
target, process, thread, bkpt = lldbutil.run_to_source_breakpoint(

View File

@ -266,14 +266,10 @@ class TestMembersAndLocalsWithSameName(TestBase):
def enable_expression_log(self):
log_file = self.getBuildArtifact("expr.log")
if configuration.is_reproducer_replay():
log_file = self.getReproducerRemappedPath(log_file)
self.runCmd("log enable -f '%s' lldb expr" % (log_file))
def disable_expression_log_and_check_for_locals(self, variables):
log_file = self.getBuildArtifact("expr.log")
if configuration.is_reproducer_replay():
log_file = self.getReproducerRemappedPath(log_file)
self.runCmd("log disable lldb expr")
local_var_regex = re.compile(r".*__lldb_local_vars::(.*);")
matched = []

View File

@ -30,19 +30,9 @@ class PlatformProcessCrashInfoTestCase(TestBase):
self.expect_expr("*tl_global_ptr",
result_type="int", result_value="45")
# Create the filespec by which to locate our a.out module.
#
# - Use the absolute path to get the module for the current variant.
# - Use the relative path for reproducers. The modules are never
# orphaned because the SB objects are leaked intentionally. This
# causes LLDB to reuse the same module for every variant, because the
# UUID is the same for all the inferiors. FindModule below only
# compares paths and is oblivious to the fact that the UUIDs are the
# same.
if configuration.is_reproducer():
filespec = lldb.SBFileSpec('a.out', False)
else:
filespec = lldb.SBFileSpec(exe, False)
# Create the filespec by which to locate our a.out module. Use the
# absolute path to get the module for the current variant.
filespec = lldb.SBFileSpec(exe, False)
# Now see if we emit the correct error when the TLS is not yet
# initialized. Let's set a breakpoint on the first instruction

View File

@ -18,7 +18,6 @@ class RuntimeTypesTestCase(TestBase):
oslist=["macosx"],
debug_info="gmodules",
bugnumber="llvm.org/pr27862")
@skipIfReproducer # FIXME: Unexpected packet during (active) replay
def test_break(self):
"""Test setting objc breakpoints using '_regexp-break' and 'breakpoint set'."""
self.build()

View File

@ -37,19 +37,9 @@ class FoundationSymtabTestCase(TestBase):
None, None, self.get_process_working_directory())
self.assertTrue(process, PROCESS_IS_VALID)
# Create the filespec by which to locate our a.out module.
#
# - Use the absolute path to get the module for the current variant.
# - Use the relative path for reproducers. The modules are never
# orphaned because the SB objects are leaked intentionally. This
# causes LLDB to reuse the same module for every variant, because the
# UUID is the same for all the inferiors. FindModule below only
# compares paths and is oblivious to the fact that the UUIDs are the
# same.
if configuration.is_reproducer():
filespec = lldb.SBFileSpec('a.out', False)
else:
filespec = lldb.SBFileSpec(exe, False)
# Create the filespec by which to locate our a.out module. Use the
# absolute path to get the module for the current variant.
filespec = lldb.SBFileSpec(exe, False)
module = target.FindModule(filespec)
self.assertTrue(module, VALID_MODULE)

View File

@ -29,7 +29,6 @@ class HiddenIvarsTestCase(TestBase):
@skipIf(
debug_info=no_match("dsym"),
bugnumber="This test requires a stripped binary and a dSYM")
@skipIfReproducer # FIXME: Unexpected packet during (passive) replay
def test_expr_stripped(self):
if self.getArchitecture() == 'i386':
self.skipTest("requires modern objc runtime")
@ -37,7 +36,6 @@ class HiddenIvarsTestCase(TestBase):
self.build()
self.expr(True)
@skipIfReproducer # FIXME: Unexpected packet during (passive) replay
def test_expr(self):
if self.getArchitecture() == 'i386':
self.skipTest("requires modern objc runtime")

View File

@ -31,8 +31,6 @@ class TestClangModuleHashMismatch(TestBase):
self.assertTrue(os.path.isdir(mod_cache), "module cache exists")
logfile = self.getBuildArtifact("host.log")
if configuration.is_reproducer_replay():
logfile = self.getReproducerRemappedPath(logfile)
self.runCmd("log enable -v -f %s lldb host" % logfile)
target, _, _, _ = lldbutil.run_to_source_breakpoint(
self, "break here", lldb.SBFileSpec("main.m"))

View File

@ -13,7 +13,6 @@ class TestClangModuleUpdate(TestBase):
mydir = TestBase.compute_mydir(__file__)
@skipIf(debug_info=no_match(["gmodules"]))
@skipIfReproducer # VFS is a snapshot.
@skipIfDarwin # rdar://76540904
def test_expr(self):
with open(self.getBuildArtifact("module.modulemap"), "w") as f:

View File

@ -21,7 +21,6 @@ class ObjCModulesTestCase(TestBase):
self.line = line_number('main.m', '// Set breakpoint 0 here.')
@skipIf(macos_version=["<", "10.12"])
@skipIfReproducer # FIXME: Unexpected packet during (active) replay
def test_expr(self):
self.build()
exe = self.getBuildArtifact("a.out")

View File

@ -23,7 +23,6 @@ class PrintObjTestCase(TestBase):
# Find the line numbers to break at.
self.line = line_number(self.source, '// Set a breakpoint here.')
@skipIfReproducer # FIXME: Unexpected packet during (active) replay
def test_print_obj(self):
"""
Test "print object" where another thread blocks the print object from making progress.

View File

@ -129,18 +129,6 @@ if is_configured('shared_libs'):
lit_config.warning("unable to inject shared library path on '{}'".format(
platform.system()))
# Support running the test suite under the lldb-repro wrapper. This makes it
# possible to capture a test suite run and then rerun all the test from the
# just captured reproducer.
lldb_repro_mode = lit_config.params.get('lldb-run-with-repro', None)
if lldb_repro_mode:
lit_config.note("Running API tests in {} mode.".format(lldb_repro_mode))
mkdir_p(config.lldb_reproducer_directory)
if lldb_repro_mode == 'capture':
config.available_features.add('lldb-repro-capture')
elif lldb_repro_mode == 'replay':
config.available_features.add('lldb-repro-replay')
lldb_use_simulator = lit_config.params.get('lldb-run-with-simulator', None)
if lldb_use_simulator:
if lldb_use_simulator == "ios":

View File

@ -18,7 +18,6 @@ config.shared_libs = @LLVM_ENABLE_SHARED_LIBS@
config.llvm_use_sanitizer = "@LLVM_USE_SANITIZER@"
config.target_triple = "@TARGET_TRIPLE@"
config.lldb_build_directory = "@LLDB_TEST_BUILD_DIRECTORY@"
config.lldb_reproducer_directory = os.path.join("@LLDB_TEST_BUILD_DIRECTORY@", "reproducers")
config.python_executable = "@Python3_EXECUTABLE@"
config.dotest_args_str = "@LLDB_DOTEST_ARGS@"
config.lldb_enable_python = @LLDB_ENABLE_PYTHON@

View File

@ -55,15 +55,6 @@ class LLDBTest(TestFormat):
# python exe as the first parameter of the command.
cmd = [executable] + self.dotest_cmd + [testPath, '-p', testFile]
if 'lldb-repro-capture' in test.config.available_features or \
'lldb-repro-replay' in test.config.available_features:
reproducer_path = os.path.join(
test.config.lldb_reproducer_directory, testFile)
if 'lldb-repro-capture' in test.config.available_features:
cmd.extend(['--capture-path', reproducer_path])
else:
cmd.extend(['--replay-path', reproducer_path])
timeoutInfo = None
try:
out, err, exitCode = lit.util.executeCommand(

View File

@ -90,23 +90,20 @@ class DyldTrieSymbolsTestCase(TestBase):
syms_ctx = stripped_target.FindSymbols("SourceBase")
self.assertEqual(syms_ctx.GetSize(), 2)
# The next part if not deterministic and potentially causes replay to
# fail when the order is different during capture and replay.
if not configuration.is_reproducer():
sym1 = syms_ctx.GetContextAtIndex(0).GetSymbol()
sym2 = syms_ctx.GetContextAtIndex(1).GetSymbol()
sym1 = syms_ctx.GetContextAtIndex(0).GetSymbol()
sym2 = syms_ctx.GetContextAtIndex(1).GetSymbol()
# one of these should be a lldb.eSymbolTypeObjCClass, the other
# should be lldb.eSymbolTypeObjCMetaClass.
if sym1.GetType() == lldb.eSymbolTypeObjCMetaClass:
self.assertEqual(sym2.GetType(), lldb.eSymbolTypeObjCClass)
# one of these should be a lldb.eSymbolTypeObjCClass, the other
# should be lldb.eSymbolTypeObjCMetaClass.
if sym1.GetType() == lldb.eSymbolTypeObjCMetaClass:
self.assertEqual(sym2.GetType(), lldb.eSymbolTypeObjCClass)
else:
if sym1.GetType() == lldb.eSymbolTypeObjCClass:
self.assertEqual(sym2.GetType(), lldb.eSymbolTypeObjCMetaClass)
else:
if sym1.GetType() == lldb.eSymbolTypeObjCClass:
self.assertEqual(sym2.GetType(), lldb.eSymbolTypeObjCMetaClass)
else:
self.assertTrue(sym1.GetType() == lldb.eSymbolTypeObjCMetaClass or sym1.GetType() == lldb.eSymbolTypeObjCClass)
self.assertTrue(sym1.GetType() == lldb.eSymbolTypeObjCMetaClass or sym1.GetType() == lldb.eSymbolTypeObjCClass)
syms_ctx = stripped_target.FindSymbols("SourceDerived._derivedValue")
self.assertEqual(syms_ctx.GetSize(), 1)
sym = syms_ctx.GetContextAtIndex(0).GetSymbol()
self.assertEqual(sym.GetType(), lldb.eSymbolTypeObjCIVar)
syms_ctx = stripped_target.FindSymbols("SourceDerived._derivedValue")
self.assertEqual(syms_ctx.GetSize(), 1)
sym = syms_ctx.GetContextAtIndex(0).GetSymbol()
self.assertEqual(sym.GetType(), lldb.eSymbolTypeObjCIVar)

View File

@ -32,7 +32,6 @@ class BundleWithDotInFilenameTestCase(TestBase):
@skipUnlessDarwin
# This test is explicitly a dSYM test, it doesn't need to run for any other config.
@skipIf(debug_info=no_match(["dsym"]))
@skipIfReproducer # File synchronization is not supported during replay.
def test_attach_and_check_dsyms(self):
"""Test attach to binary, see if the bundle dSYM is found"""
exe = self.getBuildArtifact(exe_name)

View File

@ -31,7 +31,6 @@ class DeepBundleTestCase(TestBase):
@skipUnlessDarwin
# This test is explicitly a dSYM test, it doesn't need to run for any other config.
@skipIf(debug_info=no_match(["dsym"]))
@skipIfReproducer # File synchronization is not supported during replay.
def test_attach_and_check_dsyms(self):
"""Test attach to binary, see if the framework dSYM is found"""
exe = self.getBuildArtifact(exe_name)

View File

@ -19,7 +19,6 @@ class FunctionStartsTestCase(TestBase):
@skipIfRemote
@skipUnlessDarwin
@skipIfReproducer # File synchronization is not supported during replay.
def test_function_starts_binary(self):
"""Test that we make synthetic symbols when we have the binary."""
self.build(dictionary={'CODESIGN': ''}) # Binary is getting stripped later.
@ -27,7 +26,6 @@ class FunctionStartsTestCase(TestBase):
@skipIfRemote
@skipUnlessDarwin
@skipIfReproducer # File synchronization is not supported during replay.
def test_function_starts_no_binary(self):
"""Test that we make synthetic symbols when we don't have the binary"""
self.build(dictionary={'CODESIGN': ''}) # Binary is getting stripped later.

View File

@ -13,7 +13,6 @@ class TestMacCatalyst(TestBase):
@skipIf(macos_version=["<", "10.15"])
@skipUnlessDarwin
@skipIfDarwinEmbedded
@skipIfReproducer # This is hitting https://bugs.python.org/issue22393
def test_macabi(self):
"""Test the x86_64-apple-ios-macabi target linked against a macos dylib"""
self.build()

View File

@ -15,7 +15,6 @@ class TestMacCatalystAppWithMacOSFramework(TestBase):
@skipIfDarwinEmbedded
# There is a Clang driver change missing on llvm.org.
@expectedFailureAll(bugnumber="rdar://problem/54986190>")
@skipIfReproducer # This is hitting https://bugs.python.org/issue22393
def test(self):
"""Test the x86_64-apple-ios-macabi target linked against a macos dylib"""
self.build()

View File

@ -42,7 +42,6 @@ class TestLaunchProcessPosixSpawn(TestBase):
@skipUnlessDarwin
@skipIfDarwinEmbedded
@skipTestIfFn(no_haswell)
@skipIfReproducer # Test relies on inferior output
def test_haswell(self):
self.build()
exe = self.getBuildArtifact("fat.out")
@ -52,7 +51,6 @@ class TestLaunchProcessPosixSpawn(TestBase):
@skipUnlessDarwin
@skipIfDarwinEmbedded
@skipTestIfFn(no_apple_silicon)
@skipIfReproducer # Test relies on inferior output
def test_apple_silicon(self):
self.build()
exe = self.getBuildArtifact("fat.out")

View File

@ -23,7 +23,6 @@ class TestDetachVrsProfile(TestBase):
@skipUnlessDarwin
@skipIfOutOfTreeDebugserver
@skipIfReproducer
def test_profile_and_detach(self):
"""There can be many tests in a test case - describe this test here."""
self.build()

View File

@ -6,7 +6,6 @@ import json
import unittest2
@skipIfReproducer
class TestSimulatorPlatformLaunching(TestBase):
mydir = TestBase.compute_mydir(__file__)

View File

@ -14,7 +14,6 @@ class TestInterruptThreadNames(TestBase):
@skipUnlessDarwin
@add_test_categories(['pyapi'])
@skipIfReproducer # While loop with non fixed number of iterations.
def test_with_python_api(self):
"""Test that we get thread names when interrupting a process."""
self.build()

View File

@ -19,7 +19,6 @@ class TestGetVersionForZero(TestBase):
# each debug info format.
NO_DEBUG_INFO_TESTCASE = True
@skipIfReproducer # FIXME: Unexpected packet during (passive) replay
def test_get_version_zero(self):
"""Read in a library with a version of 0.0.0. Test SBModule::GetVersion"""
self.yaml2obj("libDylib.dylib.yaml", self.getBuildArtifact("libDylib.dylib"))

View File

@ -104,7 +104,6 @@ class APIDefaultConstructorTestCase(TestBase):
import sb_compileunit
sb_compileunit.fuzz_obj(obj)
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_SBDebugger(self):
obj = lldb.SBDebugger()
if self.TraceOn():
@ -165,7 +164,6 @@ class APIDefaultConstructorTestCase(TestBase):
import sb_function
sb_function.fuzz_obj(obj)
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_SBFile(self):
sbf = lldb.SBFile()
self.assertFalse(sbf.IsValid())

View File

@ -18,7 +18,6 @@ class DisassembleRawDataTestCase(TestBase):
@no_debug_info_test
@skipIfRemote
@skipIfReproducer # GetInstructions is not instrumented.
def test_disassemble_raw_data(self):
"""Test disassembling raw bytes with the API."""
# Create a target from the debugger.

View File

@ -19,7 +19,6 @@ class Disassemble_VST1_64(TestBase):
@no_debug_info_test
@skipIfLLVMTargetMissing("ARM")
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_disassemble_invalid_vst_1_64_raw_data(self):
"""Test disassembling invalid vst1.64 raw bytes with the API."""
# Create a target from the debugger.

View File

@ -119,7 +119,6 @@ class FileHandleTestCase(lldbtest.TestBase):
return ret.GetOutput()
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_legacy_file_out_script(self):
with open(self.out_filename, 'w') as f:
self.dbg.SetOutputFileHandle(f, False)
@ -134,7 +133,6 @@ class FileHandleTestCase(lldbtest.TestBase):
self.assertEqual(readStrippedLines(f), ['2', 'FOO'])
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_legacy_file_out(self):
with open(self.out_filename, 'w') as f:
self.dbg.SetOutputFileHandle(f, False)
@ -142,7 +140,6 @@ class FileHandleTestCase(lldbtest.TestBase):
with open(self.out_filename, 'r') as f:
self.assertIn('deadbeef', f.read())
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_legacy_file_err_with_get(self):
with open(self.out_filename, 'w') as f:
self.dbg.SetErrorFileHandle(f, False)
@ -156,7 +153,6 @@ class FileHandleTestCase(lldbtest.TestBase):
self.assertTrue(re.search(r'FOOBAR', errors))
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_legacy_file_err(self):
with open(self.out_filename, 'w') as f:
self.dbg.SetErrorFileHandle(f, False)
@ -165,7 +161,6 @@ class FileHandleTestCase(lldbtest.TestBase):
self.assertIn("is not a valid command", f.read())
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_legacy_file_error(self):
with open(self.out_filename, 'w') as f:
self.dbg.SetErrorFileHandle(f, False)
@ -174,7 +169,6 @@ class FileHandleTestCase(lldbtest.TestBase):
errors = f.read()
self.assertTrue(re.search(r'error:.*lolwut', errors))
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_sbfile_type_errors(self):
sbf = lldb.SBFile()
self.assertRaises(Exception, sbf.Write, None)
@ -184,7 +178,6 @@ class FileHandleTestCase(lldbtest.TestBase):
self.assertRaises(Exception, sbf.Read, u"ham sandwich")
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_sbfile_write_fileno(self):
with open(self.out_filename, 'w') as f:
sbf = lldb.SBFile(f.fileno(), "w", False)
@ -198,7 +191,6 @@ class FileHandleTestCase(lldbtest.TestBase):
self.assertEqual(readStrippedLines(f), ['FOO', 'BAR'])
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_sbfile_write(self):
with open(self.out_filename, 'w') as f:
sbf = lldb.SBFile(f)
@ -211,7 +203,6 @@ class FileHandleTestCase(lldbtest.TestBase):
self.assertEqual(f.read().strip(), 'FOO')
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_sbfile_read_fileno(self):
with open(self.out_filename, 'w') as f:
f.write('FOO')
@ -224,7 +215,6 @@ class FileHandleTestCase(lldbtest.TestBase):
self.assertEqual(buffer[:n], b'FOO')
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_sbfile_read(self):
with open(self.out_filename, 'w') as f:
f.write('foo')
@ -239,7 +229,6 @@ class FileHandleTestCase(lldbtest.TestBase):
self.assertTrue(f.closed)
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_fileno_out(self):
with open(self.out_filename, 'w') as f:
sbf = lldb.SBFile(f.fileno(), "w", False)
@ -253,7 +242,6 @@ class FileHandleTestCase(lldbtest.TestBase):
self.assertEqual(readStrippedLines(f), ['3', 'quux'])
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_fileno_help(self):
with open(self.out_filename, 'w') as f:
sbf = lldb.SBFile(f.fileno(), "w", False)
@ -264,7 +252,6 @@ class FileHandleTestCase(lldbtest.TestBase):
self.assertTrue(re.search(r'Show a list of all debugger commands', f.read()))
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_help(self):
with open(self.out_filename, 'w') as f:
status = self.dbg.SetOutputFile(lldb.SBFile(f))
@ -274,7 +261,6 @@ class FileHandleTestCase(lldbtest.TestBase):
self.assertIn('Show a list of all debugger commands', f.read())
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_immediate(self):
with open(self.out_filename, 'w') as f:
ret = lldb.SBCommandReturnObject()
@ -291,7 +277,6 @@ class FileHandleTestCase(lldbtest.TestBase):
@skipIf(py_version=['<', (3,)])
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_immediate_string(self):
f = io.StringIO()
ret = lldb.SBCommandReturnObject()
@ -307,7 +292,6 @@ class FileHandleTestCase(lldbtest.TestBase):
@skipIf(py_version=['<', (3,)])
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_immediate_sbfile_string(self):
f = io.StringIO()
ret = lldb.SBCommandReturnObject()
@ -321,7 +305,6 @@ class FileHandleTestCase(lldbtest.TestBase):
self.assertTrue(re.search(r'Show a list of all debugger commands', output))
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_fileno_inout(self):
with open(self.in_filename, 'w') as f:
f.write("help help\n")
@ -344,7 +327,6 @@ class FileHandleTestCase(lldbtest.TestBase):
self.assertTrue(re.search(r'Show a list of all debugger commands', f.read()))
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_inout(self):
with open(self.in_filename, 'w') as f:
f.write("help help\n")
@ -362,7 +344,6 @@ class FileHandleTestCase(lldbtest.TestBase):
self.assertIn('Show a list of all debugger commands', output)
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_binary_inout(self):
with open(self.in_filename, 'w') as f:
f.write("help help\n")
@ -381,7 +362,6 @@ class FileHandleTestCase(lldbtest.TestBase):
@skipIf(py_version=['<', (3,)])
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_string_inout(self):
inf = io.StringIO("help help\np/x ~0\n")
outf = io.StringIO()
@ -398,7 +378,6 @@ class FileHandleTestCase(lldbtest.TestBase):
@skipIf(py_version=['<', (3,)])
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_bytes_inout(self):
inf = io.BytesIO(b"help help\nhelp b\n")
outf = io.BytesIO()
@ -414,7 +393,6 @@ class FileHandleTestCase(lldbtest.TestBase):
self.assertIn(b'Set a breakpoint', output)
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_fileno_error(self):
with open(self.out_filename, 'w') as f:
@ -432,7 +410,6 @@ class FileHandleTestCase(lldbtest.TestBase):
self.assertTrue(re.search(r'zork', errors))
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_replace_stdout(self):
f = io.StringIO()
with replace_stdout(f):
@ -442,7 +419,6 @@ class FileHandleTestCase(lldbtest.TestBase):
self.assertEqual(sys.stdout, f)
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_replace_stdout_with_nonfile(self):
f = io.StringIO()
with replace_stdout(f):
@ -457,7 +433,6 @@ class FileHandleTestCase(lldbtest.TestBase):
self.assertEqual(f.getvalue(), "FOO")
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_sbfile_write_borrowed(self):
with open(self.out_filename, 'w') as f:
sbf = lldb.SBFile.Create(f, borrow=True)
@ -473,7 +448,6 @@ class FileHandleTestCase(lldbtest.TestBase):
@skipIf(py_version=['<', (3,)])
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_sbfile_write_forced(self):
with open(self.out_filename, 'w') as f:
written = MutableBool(False)
@ -494,7 +468,6 @@ class FileHandleTestCase(lldbtest.TestBase):
@skipIf(py_version=['<', (3,)])
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_sbfile_write_forced_borrowed(self):
with open(self.out_filename, 'w') as f:
written = MutableBool(False)
@ -515,7 +488,6 @@ class FileHandleTestCase(lldbtest.TestBase):
@skipIf(py_version=['<', (3,)])
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_sbfile_write_string(self):
f = io.StringIO()
sbf = lldb.SBFile(f)
@ -528,7 +500,6 @@ class FileHandleTestCase(lldbtest.TestBase):
@skipIf(py_version=['<', (3,)])
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_string_out(self):
f = io.StringIO()
status = self.dbg.SetOutputFile(f)
@ -538,7 +509,6 @@ class FileHandleTestCase(lldbtest.TestBase):
@skipIf(py_version=['<', (3,)])
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_string_error(self):
f = io.StringIO()
status = self.dbg.SetErrorFile(f)
@ -549,7 +519,6 @@ class FileHandleTestCase(lldbtest.TestBase):
@skipIf(py_version=['<', (3,)])
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_sbfile_write_bytes(self):
f = io.BytesIO()
sbf = lldb.SBFile(f)
@ -561,7 +530,6 @@ class FileHandleTestCase(lldbtest.TestBase):
self.assertTrue(f.closed)
@skipIf(py_version=['<', (3,)])
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_sbfile_read_string(self):
f = io.StringIO('zork')
sbf = lldb.SBFile(f)
@ -572,7 +540,6 @@ class FileHandleTestCase(lldbtest.TestBase):
@skipIf(py_version=['<', (3,)])
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_sbfile_read_string_one_byte(self):
f = io.StringIO('z')
sbf = lldb.SBFile(f)
@ -584,7 +551,6 @@ class FileHandleTestCase(lldbtest.TestBase):
@skipIf(py_version=['<', (3,)])
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_sbfile_read_bytes(self):
f = io.BytesIO(b'zork')
sbf = lldb.SBFile(f)
@ -595,7 +561,6 @@ class FileHandleTestCase(lldbtest.TestBase):
@skipIf(py_version=['<', (3,)])
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_sbfile_out(self):
with open(self.out_filename, 'w') as f:
sbf = lldb.SBFile(f)
@ -607,7 +572,6 @@ class FileHandleTestCase(lldbtest.TestBase):
@skipIf(py_version=['<', (3,)])
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_file_out(self):
with open(self.out_filename, 'w') as f:
status = self.dbg.SetOutputFile(f)
@ -617,7 +581,6 @@ class FileHandleTestCase(lldbtest.TestBase):
self.assertEqual(f.read().strip(), '4')
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_sbfile_error(self):
with open(self.out_filename, 'w') as f:
sbf = lldb.SBFile(f)
@ -629,7 +592,6 @@ class FileHandleTestCase(lldbtest.TestBase):
self.assertTrue(re.search(r'error:.*lolwut', errors))
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_file_error(self):
with open(self.out_filename, 'w') as f:
status = self.dbg.SetErrorFile(f)
@ -640,7 +602,6 @@ class FileHandleTestCase(lldbtest.TestBase):
self.assertTrue(re.search(r'error:.*lolwut', errors))
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_exceptions(self):
self.assertRaises(Exception, lldb.SBFile, None)
self.assertRaises(Exception, lldb.SBFile, "ham sandwich")
@ -659,7 +620,6 @@ class FileHandleTestCase(lldbtest.TestBase):
@skipIf(py_version=['<', (3,)])
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_exceptions_logged(self):
messages = list()
self.dbg.SetLoggingCallback(messages.append)
@ -670,7 +630,6 @@ class FileHandleTestCase(lldbtest.TestBase):
@skipIf(py_version=['<', (3,)])
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_flush(self):
flushed = MutableBool(False)
closed = MutableBool(False)
@ -699,7 +658,6 @@ class FileHandleTestCase(lldbtest.TestBase):
self.assertFalse(f.closed)
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_fileno_flush(self):
with open(self.out_filename, 'w') as f:
f.write("foo")
@ -720,7 +678,6 @@ class FileHandleTestCase(lldbtest.TestBase):
self.assertEqual(f.read(), 'foobar')
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_close(self):
with open(self.out_filename, 'w') as f:
status = self.dbg.SetOutputFile(f)
@ -739,7 +696,6 @@ class FileHandleTestCase(lldbtest.TestBase):
@skipIf(py_version=['<', (3,)])
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_stdout(self):
f = io.StringIO()
status = self.dbg.SetOutputFile(f)
@ -748,7 +704,6 @@ class FileHandleTestCase(lldbtest.TestBase):
self.assertEqual(f.getvalue().strip().split(), ["foobar", "7"])
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_stdout_file(self):
with open(self.out_filename, 'w') as f:
status = self.dbg.SetOutputFile(f)
@ -764,7 +719,6 @@ class FileHandleTestCase(lldbtest.TestBase):
@skipIf(py_version=['<', (3,)])
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_identity(self):
f = io.StringIO()
@ -819,7 +773,6 @@ class FileHandleTestCase(lldbtest.TestBase):
self.assertEqual("foobar", f.read().strip())
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_back_and_forth(self):
with open(self.out_filename, 'w') as f:
# at each step here we're borrowing the file, so we have to keep
@ -838,7 +791,6 @@ class FileHandleTestCase(lldbtest.TestBase):
self.assertEqual(list(range(10)), list(map(int, f.read().strip().split())))
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_set_filehandle_none(self):
self.assertRaises(Exception, self.dbg.SetOutputFile, None)
self.assertRaises(Exception, self.dbg.SetOutputFile, "ham sandwich")
@ -876,7 +828,6 @@ class FileHandleTestCase(lldbtest.TestBase):
self.assertEqual(sbf.GetFile().fileno(), 0)
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def test_sbstream(self):
with open(self.out_filename, 'w') as f:

View File

@ -72,7 +72,6 @@ class HelloWorldTestCase(TestBase):
self.assertEqual(breakpoint.GetHitCount(), 1, BREAKPOINT_HIT_ONCE)
@skipIfiOSSimulator
@skipIfReproducer # File synchronization is not supported during replay.
def test_with_attach_to_process_with_id_api(self):
"""Create target, spawn a process, and attach to it with process id."""
exe = '%s_%d'%(self.testMethodName, os.getpid())
@ -104,7 +103,6 @@ class HelloWorldTestCase(TestBase):
@skipIfiOSSimulator
@skipIfAsan # FIXME: Hangs indefinitely.
@skipIfReproducer # FIXME: Unexpected packet during (active) replay
def test_with_attach_to_process_with_name_api(self):
"""Create target, spawn a process, and attach to it with process name."""
exe = '%s_%d'%(self.testMethodName, os.getpid())

View File

@ -10,7 +10,6 @@ class CommandRunInterpreterLegacyAPICase(TestBase):
NO_DEBUG_INFO_TESTCASE = True
mydir = TestBase.compute_mydir(__file__)
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def setUp(self):
TestBase.setUp(self)
@ -47,7 +46,6 @@ class CommandRunInterpreterAPICase(TestBase):
NO_DEBUG_INFO_TESTCASE = True
mydir = TestBase.compute_mydir(__file__)
@skipIfReproducer # lldb::FileSP used in typemap cannot be instrumented.
def setUp(self):
TestBase.setUp(self)

View File

@ -23,7 +23,6 @@ class ProcessAPITestCase(TestBase):
"main.cpp",
"// Set break point at this line and check variable 'my_char'.")
@skipIfReproducer # SBProcess::ReadMemory is not instrumented.
def test_read_memory(self):
"""Test Python SBProcess.ReadMemory() API."""
self.build()
@ -121,7 +120,6 @@ class ProcessAPITestCase(TestBase):
self.fail(
"Result from SBProcess.ReadUnsignedFromMemory() does not match our expected output")
@skipIfReproducer # SBProcess::WriteMemory is not instrumented.
def test_write_memory(self):
"""Test Python SBProcess.WriteMemory() API."""
self.build()
@ -180,7 +178,6 @@ class ProcessAPITestCase(TestBase):
exe=False,
startstr=b'a')
@skipIfReproducer # SBProcess::WriteMemory is not instrumented.
def test_access_my_int(self):
"""Test access 'my_int' using Python SBProcess.GetByteOrder() and other APIs."""
self.build()

View File

@ -15,7 +15,6 @@ class ProcessIOTestCase(TestBase):
mydir = TestBase.compute_mydir(__file__)
NO_DEBUG_INFO_TESTCASE = True
@skipIfReproducer
def setup_test(self):
# Get the full path to our executable to be debugged.
self.exe = self.getBuildArtifact("process_io")

View File

@ -13,7 +13,6 @@ class TestReadMemCString(TestBase):
mydir = TestBase.compute_mydir(__file__)
NO_DEBUG_INFO_TESTCASE = True
@skipIfReproducer # SBProcess::ReadCStringFromMemory is not instrumented.
def test_read_memory_c_string(self):
"""Test corner case behavior of SBProcess::ReadCStringFromMemory"""
self.build()

View File

@ -20,7 +20,6 @@ class SBDataAPICase(TestBase):
# Find the line number to break on inside main.cpp.
self.line = line_number('main.cpp', '// set breakpoint here')
@skipIfReproducer # SBData::SetData is not instrumented.
def test_byte_order_and_address_byte_size(self):
"""Test the SBData::SetData() to ensure the byte order and address
byte size are obeyed"""
@ -40,7 +39,6 @@ class SBDataAPICase(TestBase):
addr = data.GetAddress(error, 0)
self.assertEqual(addr, 0x8877665544332211);
@skipIfReproducer # SBData::SetData is not instrumented.
def test_with_run_command(self):
"""Test the SBData APIs."""
self.build()

View File

@ -22,7 +22,6 @@ class SymbolContextAPITestCase(TestBase):
'main.c', '// Find the line number of function "c" here.')
@expectedFailureAll(oslist=["windows"], bugnumber="llvm.org/pr24778")
@skipIfReproducer # FIXME: Unexpected packet during (passive) replay
def test(self):
"""Exercise SBSymbolContext API extensively."""
self.build()

View File

@ -112,7 +112,6 @@ class TargetAPITestCase(TestBase):
self.assertIsNotNone(data_section2)
self.assertEqual(data_section.name, data_section2.name)
@skipIfReproducer # SBTarget::ReadMemory is not instrumented.
def test_read_memory(self):
d = {'EXE': 'b.out'}
self.build(dictionary=d)
@ -143,7 +142,6 @@ class TargetAPITestCase(TestBase):
@skipIfWindows # stdio manipulation unsupported on Windows
@skipIfRemote # stdio manipulation unsupported on remote iOS devices<rdar://problem/54581135>
@skipIfReproducer # stdout not captured by reproducers
@skipIf(oslist=["linux"], archs=["arm", "aarch64"])
@no_debug_info_test
def test_launch_simple(self):
@ -248,18 +246,16 @@ class TargetAPITestCase(TestBase):
self.expect(my_global_var.GetValue(), exe=False,
startstr="'X'")
if not configuration.is_reproducer():
# While we are at it, let's also exercise the similar
# SBModule.FindGlobalVariables() API.
for m in target.module_iter():
if os.path.normpath(m.GetFileSpec().GetDirectory()) == self.getBuildDir() and m.GetFileSpec().GetFilename() == exe_name:
value_list = m.FindGlobalVariables(
target, 'my_global_var_of_char_type', 3)
self.assertEqual(value_list.GetSize(), 1)
self.assertEqual(
value_list.GetValueAtIndex(0).GetValue(), "'X'")
break
# While we are at it, let's also exercise the similar
# SBModule.FindGlobalVariables() API.
for m in target.module_iter():
if os.path.normpath(m.GetFileSpec().GetDirectory()) == self.getBuildDir() and m.GetFileSpec().GetFilename() == exe_name:
value_list = m.FindGlobalVariables(
target, 'my_global_var_of_char_type', 3)
self.assertEqual(value_list.GetSize(), 1)
self.assertEqual(
value_list.GetValueAtIndex(0).GetValue(), "'X'")
break
def find_compile_units(self, exe):
"""Exercise SBTarget.FindCompileUnits() API."""
@ -324,7 +320,6 @@ class TargetAPITestCase(TestBase):
@skipIfRemote
@no_debug_info_test
@skipIfReproducer # Inferior doesn't run during replay.
def test_launch_new_process_and_redirect_stdout(self):
"""Exercise SBTaget.Launch() API with redirected stdout."""
self.build()

View File

@ -143,14 +143,11 @@ class ChangeValueAPITestCase(TestBase):
thread.IsValid(),
"There should be a thread stopped due to breakpoint condition")
# Grab the stdout and make sure we changed the real values as well.
# This doesn't work for reproducers as the inferior doesn't run.
if not configuration.is_reproducer():
expected_value = "Val - 12345 Mine - 55, 98765, 55555555. Ptr - 66, 98765, 66666666"
stdout = process.GetSTDOUT(1000)
self.assertTrue(
expected_value in stdout,
"STDOUT showed changed values.")
expected_value = "Val - 12345 Mine - 55, 98765, 55555555. Ptr - 66, 98765, 66666666"
stdout = process.GetSTDOUT(1000)
self.assertTrue(
expected_value in stdout,
"STDOUT showed changed values.")
# Finally, change the stack pointer to 0, and we should not make it to
# our end breakpoint.

View File

@ -102,9 +102,4 @@ class SetWatchpointAPITestCase(TestBase):
PROCESS_EXITED)
self.dbg.DeleteTarget(target)
# The next check relies on the watchpoint being destructed, which does
# not happen during replay because objects are intentionally kept alive
# forever.
if not configuration.is_reproducer():
self.assertFalse(watchpoint.IsValid())
self.assertFalse(watchpoint.IsValid())

View File

@ -172,7 +172,6 @@ class SourceManagerTestCase(TestBase):
substrs=['Hello world'])
@skipIf(oslist=["windows"], bugnumber="llvm.org/pr44431")
@skipIfReproducer # VFS is a snapshot.
def test_modify_source_file_while_debugging(self):
"""Modify a source file while debugging the executable."""
self.build()

View File

@ -8,7 +8,6 @@ import json
import platform
import re
@skipIfReproducer
class TestAppleSimulatorOSType(gdbremote_testcase.GdbRemoteTestCaseBase):
mydir = TestBase.compute_mydir(__file__)

View File

@ -34,14 +34,11 @@ class GenericTester(TestBase):
# used for all the test cases.
self.exe_name = self.testMethodName
golden = "{}-golden-output.txt".format(self.testMethodName)
if configuration.is_reproducer():
self.golden_filename = self.getReproducerArtifact(golden)
else:
self.golden_filename = self.getBuildArtifact(golden)
self.golden_filename = self.getBuildArtifact(golden)
def tearDown(self):
"""Cleanup the test byproducts."""
if os.path.exists(self.golden_filename) and not configuration.is_reproducer():
if os.path.exists(self.golden_filename):
os.remove(self.golden_filename)
TestBase.tearDown(self)
@ -104,9 +101,6 @@ class GenericTester(TestBase):
# copy remote_path to local host
self.runCmd('platform get-file {remote} "{local}"'.format(
remote=remote_path, local=self.golden_filename))
elif configuration.is_reproducer_replay():
# Don't overwrite the golden file generated at capture time.
self.runCmd('process launch')
else:
self.runCmd(
'process launch -o "{local}"'.format(local=self.golden_filename))