[lldb] [test] Skip ObjC-based tests via 'objc' category
Replace the plethora of ObjC-implied 'skipUnlessDarwin' decorators with marking tests as 'objc' category (whenever missing), and skip all ObjC tests on non-Darwin platforms. I have used '.categories' file wherever it was present already or all (>1) tests were relying on ObjC, and explicit add_test_categories() where there was only one test. Differential Revision: https://reviews.llvm.org/D91056
This commit is contained in:
parent
462dd4f803
commit
a852cf66ea
@ -835,6 +835,13 @@ def checkWatchpointSupport():
|
||||
print("watchpoint tests will not be run because: " + reason)
|
||||
configuration.skip_categories.append("watchpoint")
|
||||
|
||||
def checkObjcSupport():
|
||||
from lldbsuite.test import lldbplatformutil
|
||||
|
||||
if not lldbplatformutil.platformIsDarwin():
|
||||
print("objc tests will be skipped because of unsupported platform")
|
||||
configuration.skip_categories.append("objc")
|
||||
|
||||
def checkDebugInfoSupport():
|
||||
import lldb
|
||||
|
||||
@ -945,6 +952,7 @@ def run_suite():
|
||||
checkLibstdcxxSupport()
|
||||
checkWatchpointSupport()
|
||||
checkDebugInfoSupport()
|
||||
checkObjcSupport()
|
||||
|
||||
# Perform LLGS tests only on platforms using it.
|
||||
configuration.llgs_platform = (
|
||||
|
||||
@ -21,7 +21,7 @@ class ExprCommandWithThrowTestCase(TestBase):
|
||||
self.main_source = "call-throws.m"
|
||||
self.main_source_spec = lldb.SBFileSpec(self.main_source)
|
||||
|
||||
@skipUnlessDarwin
|
||||
@add_test_categories(["objc"])
|
||||
def test(self):
|
||||
"""Test calling a function that throws and ObjC exception."""
|
||||
self.build()
|
||||
|
||||
@ -11,7 +11,7 @@ class ContextObjectObjcTestCase(TestBase):
|
||||
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@skipUnlessDarwin
|
||||
@add_test_categories(["objc"])
|
||||
def test_context_object_objc(self):
|
||||
"""Tests expression evaluation in context of an objc class."""
|
||||
self.build()
|
||||
|
||||
@ -88,7 +88,7 @@ class ExprDiagnosticsTestCase(TestBase):
|
||||
self.assertFalse(value.GetError().Success())
|
||||
self.assertIn("error: <user expression 9>:1:8: redefinition of 'Redef'\nstruct Redef { float y; };\n ^\n<user expression 8>:1:8: previous definition is here\nstruct Redef { double x; };\n ^", value.GetError().GetCString())
|
||||
|
||||
@skipUnlessDarwin
|
||||
@add_test_categories(["objc"])
|
||||
def test_source_locations_from_objc_modules(self):
|
||||
self.build()
|
||||
|
||||
|
||||
@ -14,9 +14,8 @@ class TestImportBuiltinFileID(TestBase):
|
||||
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@skipUnlessDarwin
|
||||
@skipIfDarwinEmbedded
|
||||
@add_test_categories(["gmodules"])
|
||||
@add_test_categories(["gmodules", "objc"])
|
||||
def test_import_builtin_fileid(self):
|
||||
self.build()
|
||||
|
||||
|
||||
@ -7,8 +7,7 @@ class TestNamespaceLocalVarSameNameObjC(TestBase):
|
||||
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@skipUnlessDarwin
|
||||
@add_test_categories(["gmodules"])
|
||||
@add_test_categories(["gmodules", "objc"])
|
||||
def test_namespace_local_var_same_name_obj_c(self):
|
||||
self.build()
|
||||
|
||||
|
||||
@ -20,9 +20,9 @@ class PersistObjCPointeeType(TestBase):
|
||||
# Find the line number to break for main.cpp.
|
||||
self.line = line_number('main.m', '// break here')
|
||||
|
||||
@skipUnlessDarwin
|
||||
@skipIf(archs=["i386", "i686"])
|
||||
@skipIf(debug_info="gmodules", archs=['arm64', 'armv7', 'armv7k', 'arm64e', 'arm64_32']) # compile error with gmodules for iOS
|
||||
@add_test_categories(["objc"])
|
||||
def test_with(self):
|
||||
"""Test that we can p *objcObject"""
|
||||
self.build()
|
||||
|
||||
@ -21,7 +21,7 @@ class PoVerbosityTestCase(TestBase):
|
||||
self.line = line_number('main.m',
|
||||
'// Stop here')
|
||||
|
||||
@skipUnlessDarwin
|
||||
@add_test_categories(["objc"])
|
||||
def test(self):
|
||||
"""Test that the po command acts correctly."""
|
||||
self.build()
|
||||
|
||||
@ -23,7 +23,7 @@ class ObjCTypeQueryTestCase(TestBase):
|
||||
self.line = line_number(
|
||||
'main.m', "// Set breakpoint here, then do 'expr (NSArray*)array_token'.")
|
||||
|
||||
@skipUnlessDarwin
|
||||
@add_test_categories(["objc"])
|
||||
def test(self):
|
||||
"""The expression parser's type search should be wider than the current compilation unit."""
|
||||
self.build()
|
||||
|
||||
1
lldb/test/API/commands/frame/recognizer/.categories
Normal file
1
lldb/test/API/commands/frame/recognizer/.categories
Normal file
@ -0,0 +1 @@
|
||||
objc
|
||||
@ -13,11 +13,11 @@ from lldbsuite.test.lldbtest import *
|
||||
from lldbsuite.test import lldbutil
|
||||
|
||||
|
||||
@skipUnlessDarwin
|
||||
class TestObjCBreakpoints(TestBase):
|
||||
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@add_test_categories(["objc"])
|
||||
def test_break(self):
|
||||
"""Test setting Objective-C specific breakpoints (DWARF in .o files)."""
|
||||
self.build()
|
||||
|
||||
@ -14,7 +14,6 @@ from ObjCDataFormatterTestCase import ObjCDataFormatterTestCase
|
||||
|
||||
class ObjCDataFormatterCF(ObjCDataFormatterTestCase):
|
||||
|
||||
@skipUnlessDarwin
|
||||
def test_coreframeworks_and_run_command(self):
|
||||
"""Test formatters for Core OSX frameworks."""
|
||||
self.build()
|
||||
|
||||
@ -14,7 +14,6 @@ from ObjCDataFormatterTestCase import ObjCDataFormatterTestCase
|
||||
|
||||
class ObjCDataFormatterExpr(ObjCDataFormatterTestCase):
|
||||
|
||||
@skipUnlessDarwin
|
||||
def test_expr_with_run_command(self):
|
||||
"""Test common cases of expression parser <--> formatters interaction."""
|
||||
self.build()
|
||||
|
||||
@ -14,7 +14,6 @@ from ObjCDataFormatterTestCase import ObjCDataFormatterTestCase
|
||||
|
||||
class ObjCDataFormatterKVO(ObjCDataFormatterTestCase):
|
||||
|
||||
@skipUnlessDarwin
|
||||
def test_kvo_with_run_command(self):
|
||||
"""Test the behavior of formatters when KVO is in use."""
|
||||
self.build()
|
||||
|
||||
@ -14,7 +14,6 @@ from ObjCDataFormatterTestCase import ObjCDataFormatterTestCase
|
||||
|
||||
class ObjCDataFormatterNSBundle(ObjCDataFormatterTestCase):
|
||||
|
||||
@skipUnlessDarwin
|
||||
def test_nsbundle_with_run_command(self):
|
||||
"""Test formatters for NSBundle."""
|
||||
self.appkit_tester_impl(self.nsbundle_data_formatter_commands)
|
||||
|
||||
@ -14,7 +14,6 @@ from ObjCDataFormatterTestCase import ObjCDataFormatterTestCase
|
||||
|
||||
class ObjCDataFormatterNSContainer(ObjCDataFormatterTestCase):
|
||||
|
||||
@skipUnlessDarwin
|
||||
def test_nscontainers_with_run_command(self):
|
||||
"""Test formatters for NS container classes."""
|
||||
self.appkit_tester_impl(self.nscontainers_data_formatter_commands)
|
||||
|
||||
@ -14,7 +14,6 @@ from ObjCDataFormatterTestCase import ObjCDataFormatterTestCase
|
||||
|
||||
class ObjCDataFormatterNSData(ObjCDataFormatterTestCase):
|
||||
|
||||
@skipUnlessDarwin
|
||||
def test_nsdata_with_run_command(self):
|
||||
"""Test formatters for NSData."""
|
||||
self.appkit_tester_impl(self.nsdata_data_formatter_commands)
|
||||
|
||||
@ -15,7 +15,6 @@ import datetime
|
||||
|
||||
class ObjCDataFormatterNSDate(ObjCDataFormatterTestCase):
|
||||
|
||||
@skipUnlessDarwin
|
||||
def test_nsdate_with_run_command(self):
|
||||
"""Test formatters for NSDate."""
|
||||
self.appkit_tester_impl(self.nsdate_data_formatter_commands)
|
||||
|
||||
@ -14,7 +14,6 @@ from ObjCDataFormatterTestCase import ObjCDataFormatterTestCase
|
||||
|
||||
class ObjCDataFormatterNSError(ObjCDataFormatterTestCase):
|
||||
|
||||
@skipUnlessDarwin
|
||||
def test_nserror_with_run_command(self):
|
||||
"""Test formatters for NSError."""
|
||||
self.appkit_tester_impl(self.nserror_data_formatter_commands)
|
||||
|
||||
@ -14,7 +14,6 @@ from ObjCDataFormatterTestCase import ObjCDataFormatterTestCase
|
||||
|
||||
class ObjCDataFormatterNSURL(ObjCDataFormatterTestCase):
|
||||
|
||||
@skipUnlessDarwin
|
||||
def test_nsurl_with_run_command(self):
|
||||
"""Test formatters for NSURL."""
|
||||
self.appkit_tester_impl(self.nsurl_data_formatter_commands)
|
||||
|
||||
@ -14,7 +14,6 @@ from ObjCDataFormatterTestCase import ObjCDataFormatterTestCase
|
||||
|
||||
class ObjCDataFormatterNSPlain(ObjCDataFormatterTestCase):
|
||||
|
||||
@skipUnlessDarwin
|
||||
def test_plain_objc_with_run_command(self):
|
||||
"""Test basic ObjC formatting behavior."""
|
||||
self.build()
|
||||
|
||||
@ -14,7 +14,6 @@ from ObjCDataFormatterTestCase import ObjCDataFormatterTestCase
|
||||
|
||||
class ObjCDataFormatterNSException(ObjCDataFormatterTestCase):
|
||||
|
||||
@skipUnlessDarwin
|
||||
def test_nsexception_with_run_command(self):
|
||||
"""Test formatters for NSException."""
|
||||
self.appkit_tester_impl(self.nsexception_data_formatter_commands)
|
||||
|
||||
@ -14,7 +14,7 @@ class SetDataTestCase(TestBase):
|
||||
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@skipUnlessDarwin
|
||||
@add_test_categories(["objc"])
|
||||
def test_set_data(self):
|
||||
"""Test setting the contents of variables and registers using raw data."""
|
||||
self.build()
|
||||
|
||||
@ -20,6 +20,7 @@ class TsanMultipleTestCase(TestBase):
|
||||
@skipIfFreeBSD # llvm.org/pr21136 runtimes not yet available by default
|
||||
@skipIfRemote
|
||||
@skipUnlessThreadSanitizer
|
||||
@add_test_categories(["objc"])
|
||||
def test(self):
|
||||
self.build()
|
||||
self.tsan_tests()
|
||||
|
||||
@ -8,7 +8,6 @@ class TestBitfieldIvars(TestBase):
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
|
||||
@skipUnlessDarwin
|
||||
def test(self):
|
||||
self.build()
|
||||
lldbutil.run_to_source_breakpoint(self, "// break here", lldb.SBFileSpec("main.m"))
|
||||
|
||||
@ -18,7 +18,6 @@ class TestObjCIvarsInBlocks(TestBase):
|
||||
self.class_source = "ivars-in-blocks.m"
|
||||
self.class_source_file_spec = lldb.SBFileSpec(self.class_source)
|
||||
|
||||
@skipUnlessDarwin
|
||||
@add_test_categories(['pyapi'])
|
||||
@skipIf(dwarf_version=['<', '4'])
|
||||
@expectedFailureAll(
|
||||
|
||||
@ -12,7 +12,6 @@ class TestRealDefinition(TestBase):
|
||||
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@skipUnlessDarwin
|
||||
def test_frame_var_after_stop_at_implementation(self):
|
||||
"""Test that we can find the implementation for an objective C type"""
|
||||
if self.getArchitecture() == 'i386':
|
||||
|
||||
@ -20,7 +20,6 @@ class TestObjCDirectDispatchStepping(TestBase):
|
||||
# Find the line numbers that we will step to in main:
|
||||
self.main_source = lldb.SBFileSpec("stepping-tests.m")
|
||||
|
||||
@skipUnlessDarwin
|
||||
@add_test_categories(['pyapi', 'basic_process'])
|
||||
def test_with_python_api(self):
|
||||
"""Test stepping through the 'direct dispatch' optimized method calls."""
|
||||
|
||||
@ -15,7 +15,6 @@ class ObjCExceptionsTestCase(TestBase):
|
||||
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@skipUnlessDarwin
|
||||
def test_objc_exceptions_at_throw(self):
|
||||
self.build()
|
||||
|
||||
@ -126,7 +125,6 @@ class ObjCExceptionsTestCase(TestBase):
|
||||
for n in ["objc_exception_throw", "foo(int)", "main"]:
|
||||
self.assertTrue(n in names, "%s is in the exception backtrace (%s)" % (n, names))
|
||||
|
||||
@skipUnlessDarwin
|
||||
def test_objc_exceptions_at_abort(self):
|
||||
self.build()
|
||||
|
||||
@ -183,7 +181,6 @@ class ObjCExceptionsTestCase(TestBase):
|
||||
for n in ["objc_exception_throw", "foo(int)", "rethrow(int)", "main"]:
|
||||
self.assertEqual(len([f for f in history_thread.frames if f.GetFunctionName() == n]), 1)
|
||||
|
||||
@skipUnlessDarwin
|
||||
def test_cxx_exceptions_at_abort(self):
|
||||
self.build()
|
||||
|
||||
|
||||
@ -54,12 +54,10 @@ class ForwardDeclTestCase(TestBase):
|
||||
self.expect("expression [j getMember]", VARIABLES_DISPLAYED_CORRECTLY,
|
||||
substrs=["= 0x"])
|
||||
|
||||
@skipUnlessDarwin
|
||||
def test_expr(self):
|
||||
self.do_test()
|
||||
|
||||
@no_debug_info_test
|
||||
@skipUnlessDarwin
|
||||
@skipIf(compiler=no_match("clang"))
|
||||
@skipIf(compiler_version=["<", "7.0"])
|
||||
def test_debug_names(self):
|
||||
|
||||
@ -23,7 +23,6 @@ class ConstStringTestCase(TestBase):
|
||||
self.main_source = "const-strings.m"
|
||||
self.line = line_number(self.main_source, '// Set breakpoint here.')
|
||||
|
||||
@skipUnlessDarwin
|
||||
def test_break(self):
|
||||
"""Test constant string generation amd comparison by the expression parser."""
|
||||
self.build(dictionary=self.d)
|
||||
|
||||
@ -10,7 +10,6 @@ from lldbsuite.test.lldbtest import *
|
||||
from lldbsuite.test import lldbutil
|
||||
|
||||
|
||||
@skipUnlessDarwin
|
||||
class FoundationDisassembleTestCase(TestBase):
|
||||
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@ -16,7 +16,6 @@ from lldbsuite.test import lldbutil
|
||||
file_index = 0
|
||||
|
||||
|
||||
@skipUnlessDarwin
|
||||
class FoundationTestCase(TestBase):
|
||||
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@ -10,7 +10,6 @@ from lldbsuite.test.lldbtest import *
|
||||
from lldbsuite.test import lldbutil
|
||||
|
||||
|
||||
@skipUnlessDarwin
|
||||
class FoundationTestCase2(TestBase):
|
||||
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@ -10,7 +10,6 @@ from lldbsuite.test.lldbtest import *
|
||||
from lldbsuite.test import lldbutil
|
||||
|
||||
|
||||
@skipUnlessDarwin
|
||||
class FoundationTestCaseNSArray(TestBase):
|
||||
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@ -10,7 +10,6 @@ from lldbsuite.test.lldbtest import *
|
||||
from lldbsuite.test import lldbutil
|
||||
|
||||
|
||||
@skipUnlessDarwin
|
||||
class FoundationTestCaseNSError(TestBase):
|
||||
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@ -10,7 +10,6 @@ from lldbsuite.test.lldbtest import *
|
||||
from lldbsuite.test import lldbutil
|
||||
|
||||
|
||||
@skipUnlessDarwin
|
||||
class FoundationTestCaseString(TestBase):
|
||||
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@ -24,7 +24,6 @@ class ObjectDescriptionAPITestCase(TestBase):
|
||||
self.source, '// Set break point at this line.')
|
||||
|
||||
# rdar://problem/10857337
|
||||
@skipUnlessDarwin
|
||||
@add_test_categories(['pyapi'])
|
||||
def test_find_global_variables_then_object_description(self):
|
||||
"""Exercise SBTarget.FindGlobalVariables() API."""
|
||||
|
||||
@ -10,7 +10,6 @@ from lldbsuite.test.lldbtest import *
|
||||
from lldbsuite.test import lldbutil
|
||||
|
||||
|
||||
@skipUnlessDarwin
|
||||
class RuntimeTypesTestCase(TestBase):
|
||||
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@ -8,7 +8,6 @@ from lldbsuite.test.lldbtest import *
|
||||
from lldbsuite.test import lldbutil
|
||||
|
||||
|
||||
@skipUnlessDarwin
|
||||
class FoundationSymtabTestCase(TestBase):
|
||||
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@ -17,7 +17,6 @@ class TestObjCGlobalVar(TestBase):
|
||||
TestBase.setUp(self)
|
||||
self.main_source = lldb.SBFileSpec("main.m")
|
||||
|
||||
@skipUnlessDarwin
|
||||
@add_test_categories(['pyapi'])
|
||||
def test_with_python_api(self):
|
||||
"""Test that a global ObjC object found before the process is started updates correctly."""
|
||||
|
||||
@ -26,7 +26,6 @@ class HiddenIvarsTestCase(TestBase):
|
||||
# localized
|
||||
self.shlib_names = ["InternalDefiner"]
|
||||
|
||||
@skipUnlessDarwin
|
||||
@skipIf(
|
||||
debug_info=no_match("dsym"),
|
||||
bugnumber="This test requires a stripped binary and a dSYM")
|
||||
@ -38,7 +37,6 @@ class HiddenIvarsTestCase(TestBase):
|
||||
self.build()
|
||||
self.expr(True)
|
||||
|
||||
@skipUnlessDarwin
|
||||
@skipIfReproducer # FIXME: Unexpected packet during (passive) replay
|
||||
def test_expr(self):
|
||||
if self.getArchitecture() == 'i386':
|
||||
@ -47,7 +45,6 @@ class HiddenIvarsTestCase(TestBase):
|
||||
self.build()
|
||||
self.expr(False)
|
||||
|
||||
@skipUnlessDarwin
|
||||
@skipIf(
|
||||
debug_info=no_match("dsym"),
|
||||
bugnumber="This test requires a stripped binary and a dSYM")
|
||||
@ -58,7 +55,6 @@ class HiddenIvarsTestCase(TestBase):
|
||||
self.build()
|
||||
self.frame_var(True)
|
||||
|
||||
@skipUnlessDarwin
|
||||
def test_frame_variable(self):
|
||||
if self.getArchitecture() == 'i386':
|
||||
self.skipTest("requires modern objc runtime")
|
||||
@ -67,7 +63,6 @@ class HiddenIvarsTestCase(TestBase):
|
||||
self.frame_var(False)
|
||||
|
||||
@expectedFailure("rdar://18683637")
|
||||
@skipUnlessDarwin
|
||||
def test_frame_variable_across_modules(self):
|
||||
if self.getArchitecture() == 'i386':
|
||||
self.skipTest("requires modern objc runtime")
|
||||
|
||||
@ -15,7 +15,6 @@ class ObjCiVarIMPTestCase(TestBase):
|
||||
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@skipUnlessDarwin
|
||||
@skipIf(archs=['i386']) # objc file does not build for i386
|
||||
@no_debug_info_test
|
||||
def test_imp_ivar_type(self):
|
||||
|
||||
@ -12,7 +12,6 @@ from lldbsuite.test import lldbutil
|
||||
class TestClangModuleAppUpdate(TestBase):
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@skipUnlessDarwin
|
||||
@skipIf(debug_info=no_match(["gmodules"]))
|
||||
def test_rebuild_app_modules_untouched(self):
|
||||
with open(self.getBuildArtifact("module.modulemap"), "w") as f:
|
||||
|
||||
@ -20,7 +20,6 @@ class ObjCModulesAutoImportTestCase(TestBase):
|
||||
# Find the line number to break inside main().
|
||||
self.line = line_number('main.m', '// Set breakpoint 0 here.')
|
||||
|
||||
@skipUnlessDarwin
|
||||
@skipIf(macos_version=["<", "10.12"])
|
||||
def test_expr(self):
|
||||
self.build()
|
||||
|
||||
@ -16,7 +16,6 @@ class ObjCModulesTestCase(TestBase):
|
||||
NO_DEBUG_INFO_TESTCASE = True
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@skipUnlessDarwin
|
||||
def test_expr(self):
|
||||
self.build()
|
||||
self.main_source_file = lldb.SBFileSpec("main.m")
|
||||
|
||||
@ -7,7 +7,6 @@ class TestCase(TestBase):
|
||||
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@skipUnlessDarwin
|
||||
def test(self):
|
||||
self.build()
|
||||
lldbutil.run_to_source_breakpoint(self, "// break here", lldb.SBFileSpec("main.m"))
|
||||
|
||||
@ -12,7 +12,6 @@ from lldbsuite.test import lldbutil
|
||||
class TestClangModuleHashMismatch(TestBase):
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@skipUnlessDarwin
|
||||
@skipIf(debug_info=no_match(["gmodules"]))
|
||||
def test_expr(self):
|
||||
with open(self.getBuildArtifact("module.modulemap"), "w") as f:
|
||||
|
||||
@ -19,7 +19,6 @@ class IncompleteModulesTestCase(TestBase):
|
||||
# Find the line number to break inside main().
|
||||
self.line = line_number('main.m', '// Set breakpoint 0 here.')
|
||||
|
||||
@skipUnlessDarwin
|
||||
@skipIf(debug_info=no_match(["gmodules"]))
|
||||
def test_expr(self):
|
||||
self.build()
|
||||
|
||||
@ -15,7 +15,6 @@ class ModulesInlineFunctionsTestCase(TestBase):
|
||||
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@skipUnlessDarwin
|
||||
@skipIf(macos_version=["<", "10.12"], debug_info=no_match(["gmodules"]))
|
||||
def test_expr(self):
|
||||
self.build()
|
||||
|
||||
@ -11,7 +11,6 @@ class TestCase(TestBase):
|
||||
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@skipUnlessDarwin
|
||||
def test(self):
|
||||
self.build()
|
||||
lldbutil.run_to_source_breakpoint(self,"// break here", lldb.SBFileSpec("main.c"))
|
||||
|
||||
@ -12,7 +12,6 @@ from lldbsuite.test import lldbutil
|
||||
class TestClangModuleUpdate(TestBase):
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@skipUnlessDarwin
|
||||
@skipIf(debug_info=no_match(["gmodules"]))
|
||||
@skipIfReproducer # VFS is a snapshot.
|
||||
def test_expr(self):
|
||||
|
||||
@ -20,7 +20,6 @@ class ObjCModulesTestCase(TestBase):
|
||||
# Find the line number to break inside main().
|
||||
self.line = line_number('main.m', '// Set breakpoint 0 here.')
|
||||
|
||||
@skipUnlessDarwin
|
||||
@skipIf(macos_version=["<", "10.12"])
|
||||
@skipIfReproducer # FIXME: Unexpected packet during (active) replay
|
||||
def test_expr(self):
|
||||
|
||||
@ -14,7 +14,6 @@ class ObjCXXTestCase(TestBase):
|
||||
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@skipUnlessDarwin
|
||||
def test_break(self):
|
||||
"""Test ivars of Objective-C++ classes"""
|
||||
if self.getArchitecture() == 'i386':
|
||||
|
||||
@ -20,7 +20,6 @@ class ObjCDynamicValueTestCase(TestBase):
|
||||
|
||||
self.line = line_number('main.m', '// Set breakpoint here.')
|
||||
|
||||
@skipUnlessDarwin
|
||||
@add_test_categories(['pyapi'])
|
||||
def test_get_baseclass(self):
|
||||
"""Test fetching ObjC dynamic values."""
|
||||
|
||||
@ -20,7 +20,6 @@ class TestObjCBuiltinTypes(TestBase):
|
||||
self.break_line = line_number(
|
||||
self.main_source, '// Set breakpoint here.')
|
||||
|
||||
@skipUnlessDarwin
|
||||
@add_test_categories(['pyapi'])
|
||||
#<rdar://problem/10591460> [regression] Can't print ivar value: error: reference to 'id' is ambiguous
|
||||
def test_with_python_api(self):
|
||||
|
||||
@ -23,7 +23,6 @@ class ObjCCheckerTestCase(TestBase):
|
||||
# Find the line number to break for main.c.
|
||||
self.source_name = 'main.m'
|
||||
|
||||
@skipUnlessDarwin
|
||||
@add_test_categories(['pyapi'])
|
||||
def test_objc_checker(self):
|
||||
"""Test that checkers catch unrecognized selectors"""
|
||||
|
||||
@ -21,7 +21,6 @@ class TestObjCClassMethod(TestBase):
|
||||
self.break_line = line_number(
|
||||
self.main_source, '// Set breakpoint here.')
|
||||
|
||||
@skipUnlessDarwin
|
||||
@add_test_categories(['pyapi'])
|
||||
def test_with_python_api(self):
|
||||
"""Test calling functions in class methods."""
|
||||
|
||||
@ -10,7 +10,6 @@ from lldbsuite.test.lldbtest import *
|
||||
from lldbsuite.test import lldbutil
|
||||
|
||||
|
||||
@skipUnlessDarwin
|
||||
class ObjCDynamicSBTypeTestCase(TestBase):
|
||||
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@ -29,7 +29,6 @@ class ObjCDynamicValueTestCase(TestBase):
|
||||
self.main_before_setProperty_line = line_number(
|
||||
self.source_name, '// Break here to see if we can step into real method.')
|
||||
|
||||
@skipUnlessDarwin
|
||||
@add_test_categories(['pyapi'])
|
||||
@expectedFailureDarwin("llvm.org/pr20271 rdar://18684107")
|
||||
def test_get_objc_dynamic_vals(self):
|
||||
|
||||
@ -1,5 +1,3 @@
|
||||
from lldbsuite.test import lldbinline
|
||||
from lldbsuite.test import decorators
|
||||
|
||||
lldbinline.MakeInlineTest(
|
||||
__file__, globals(), [decorators.skipUnlessDarwin])
|
||||
lldbinline.MakeInlineTest(__file__, globals(), [])
|
||||
|
||||
@ -20,7 +20,6 @@ class TestObjCIvarOffsets(TestBase):
|
||||
self.stop_line = line_number(
|
||||
self.main_source, '// Set breakpoint here.')
|
||||
|
||||
@skipUnlessDarwin
|
||||
@add_test_categories(['pyapi'])
|
||||
def test_with_python_api(self):
|
||||
"""Test printing ObjC objects that use unbacked properties"""
|
||||
|
||||
@ -1,5 +1,3 @@
|
||||
from lldbsuite.test import lldbinline
|
||||
from lldbsuite.test import decorators
|
||||
|
||||
lldbinline.MakeInlineTest(
|
||||
__file__, globals(), [decorators.skipUnlessDarwin])
|
||||
lldbinline.MakeInlineTest(__file__, globals(), [])
|
||||
|
||||
@ -20,7 +20,6 @@ class TestObjCIvarStripped(TestBase):
|
||||
self.stop_line = line_number(
|
||||
self.main_source, '// Set breakpoint here.')
|
||||
|
||||
@skipUnlessDarwin
|
||||
@skipIf(
|
||||
debug_info=no_match("dsym"),
|
||||
bugnumber="This test requires a stripped binary and a dSYM")
|
||||
|
||||
@ -11,7 +11,6 @@ from ObjCNewSyntaxTest import ObjCNewSyntaxTest
|
||||
|
||||
class ObjCNewSyntaxTestCaseArray(ObjCNewSyntaxTest):
|
||||
|
||||
@skipUnlessDarwin
|
||||
@skipIf(macos_version=["<", "10.12"])
|
||||
@expectedFailureAll(archs=["i[3-6]86"])
|
||||
def test_read_array(self):
|
||||
@ -27,7 +26,6 @@ class ObjCNewSyntaxTestCaseArray(ObjCNewSyntaxTest):
|
||||
VARIABLES_DISPLAYED_CORRECTLY,
|
||||
substrs=["foo"])
|
||||
|
||||
@skipUnlessDarwin
|
||||
@skipIf(macos_version=["<", "10.12"])
|
||||
@expectedFailureAll(archs=["i[3-6]86"])
|
||||
def test_update_array(self):
|
||||
@ -43,7 +41,6 @@ class ObjCNewSyntaxTestCaseArray(ObjCNewSyntaxTest):
|
||||
VARIABLES_DISPLAYED_CORRECTLY,
|
||||
substrs=["bar"])
|
||||
|
||||
@skipUnlessDarwin
|
||||
@skipIf(macos_version=["<", "10.12"])
|
||||
@expectedFailureAll(archs=["i[3-6]86"])
|
||||
def test_array_literal(self):
|
||||
|
||||
@ -11,7 +11,6 @@ from ObjCNewSyntaxTest import ObjCNewSyntaxTest
|
||||
|
||||
class ObjCNewSyntaxTestCaseDictionary(ObjCNewSyntaxTest):
|
||||
|
||||
@skipUnlessDarwin
|
||||
@skipIf(macos_version=["<", "10.12"])
|
||||
@expectedFailureAll(archs=["i[3-6]86"])
|
||||
def test_read_dictionary(self):
|
||||
@ -27,7 +26,6 @@ class ObjCNewSyntaxTestCaseDictionary(ObjCNewSyntaxTest):
|
||||
VARIABLES_DISPLAYED_CORRECTLY,
|
||||
substrs=["value"])
|
||||
|
||||
@skipUnlessDarwin
|
||||
@skipIf(macos_version=["<", "10.12"])
|
||||
@expectedFailureAll(archs=["i[3-6]86"])
|
||||
def test_update_dictionary(self):
|
||||
@ -43,7 +41,6 @@ class ObjCNewSyntaxTestCaseDictionary(ObjCNewSyntaxTest):
|
||||
VARIABLES_DISPLAYED_CORRECTLY,
|
||||
substrs=["object"])
|
||||
|
||||
@skipUnlessDarwin
|
||||
@skipIf(macos_version=["<", "10.12"])
|
||||
@expectedFailureAll(archs=["i[3-6]86"])
|
||||
def test_dictionary_literal(self):
|
||||
|
||||
@ -11,7 +11,6 @@ from ObjCNewSyntaxTest import ObjCNewSyntaxTest
|
||||
|
||||
class ObjCNewSyntaxTestCaseLiteral(ObjCNewSyntaxTest):
|
||||
|
||||
@skipUnlessDarwin
|
||||
@skipIf(macos_version=["<", "10.12"])
|
||||
@expectedFailureAll(archs=["i[3-6]86"])
|
||||
def test_char_literal(self):
|
||||
@ -20,7 +19,6 @@ class ObjCNewSyntaxTestCaseLiteral(ObjCNewSyntaxTest):
|
||||
self.expect("expr --object-description -- @'a'",
|
||||
VARIABLES_DISPLAYED_CORRECTLY, substrs=[str(ord('a'))])
|
||||
|
||||
@skipUnlessDarwin
|
||||
@skipIf(macos_version=["<", "10.12"])
|
||||
@expectedFailureAll(archs=["i[3-6]86"])
|
||||
def test_integer_literals(self):
|
||||
@ -51,7 +49,6 @@ class ObjCNewSyntaxTestCaseLiteral(ObjCNewSyntaxTest):
|
||||
VARIABLES_DISPLAYED_CORRECTLY,
|
||||
substrs=["1"])
|
||||
|
||||
@skipUnlessDarwin
|
||||
@skipIf(macos_version=["<", "10.12"])
|
||||
@expectedFailureAll(archs=["i[3-6]86"])
|
||||
def test_float_literal(self):
|
||||
@ -60,7 +57,6 @@ class ObjCNewSyntaxTestCaseLiteral(ObjCNewSyntaxTest):
|
||||
self.expect("expr -- @123.45", VARIABLES_DISPLAYED_CORRECTLY,
|
||||
substrs=["NSNumber", "123.45"])
|
||||
|
||||
@skipUnlessDarwin
|
||||
@skipIf(macos_version=["<", "10.12"])
|
||||
@expectedFailureAll(archs=["i[3-6]86"])
|
||||
def test_expressions_in_literals(self):
|
||||
|
||||
@ -19,7 +19,6 @@ from lldbsuite.test import lldbutil
|
||||
# test failure: objc_optimized does not work for "-C clang -A i386"
|
||||
|
||||
|
||||
@skipUnlessDarwin
|
||||
class ObjcOptimizedTestCase(TestBase):
|
||||
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@ -21,7 +21,6 @@ class ObjCPropertyTestCase(TestBase):
|
||||
# Find the line number to break for main.c.
|
||||
self.source_name = 'main.m'
|
||||
|
||||
@skipUnlessDarwin
|
||||
@add_test_categories(['pyapi'])
|
||||
def test_objc_properties(self):
|
||||
"""Test that expr uses the correct property getters and setters"""
|
||||
|
||||
@ -3,5 +3,4 @@ from lldbsuite.test import decorators
|
||||
|
||||
lldbinline.MakeInlineTest(
|
||||
__file__, globals(), [
|
||||
decorators.skipUnlessDarwin,
|
||||
decorators.skipIf(archs=["i386", "i686"])])
|
||||
|
||||
@ -20,7 +20,6 @@ class TestObjCStaticMethodStripped(TestBase):
|
||||
self.break_line = line_number(
|
||||
self.main_source, '// Set breakpoint here.')
|
||||
|
||||
@skipUnlessDarwin
|
||||
@add_test_categories(['pyapi'])
|
||||
@skipIf(
|
||||
debug_info=no_match("dsym"),
|
||||
|
||||
@ -20,7 +20,6 @@ class TestObjCStaticMethod(TestBase):
|
||||
self.break_line = line_number(
|
||||
self.main_source, '// Set breakpoint here.')
|
||||
|
||||
@skipUnlessDarwin
|
||||
@add_test_categories(['pyapi'])
|
||||
#<rdar://problem/9745789> "expression" can't call functions in class methods
|
||||
def test_with_python_api(self):
|
||||
|
||||
@ -29,7 +29,6 @@ class TestObjCStepping(TestBase):
|
||||
self.stepped_past_nil_line = line_number(
|
||||
self.main_source, '// Step over nil should stop here.')
|
||||
|
||||
@skipUnlessDarwin
|
||||
@add_test_categories(['pyapi', 'basic_process'])
|
||||
def test_with_python_api(self):
|
||||
"""Test stepping through ObjC method dispatch in various forms."""
|
||||
|
||||
@ -20,7 +20,6 @@ class TestObjCStructArgument(TestBase):
|
||||
self.break_line = line_number(
|
||||
self.main_source, '// Set breakpoint here.')
|
||||
|
||||
@skipUnlessDarwin
|
||||
@add_test_categories(['pyapi'])
|
||||
@skipIf(debug_info=no_match(["gmodules"]), oslist=['ios', 'watchos', 'tvos', 'bridgeos'], archs=['armv7', 'arm64']) # this test program only builds for ios with -gmodules
|
||||
def test_with_python_api(self):
|
||||
|
||||
@ -20,7 +20,6 @@ class TestObjCClassMethod(TestBase):
|
||||
self.break_line = line_number(
|
||||
self.main_source, '// Set breakpoint here.')
|
||||
|
||||
@skipUnlessDarwin
|
||||
@add_test_categories(['pyapi'])
|
||||
def test_with_python_api(self):
|
||||
"""Test calling functions in class methods."""
|
||||
|
||||
@ -20,7 +20,6 @@ class TestObjCSuperMethod(TestBase):
|
||||
self.break_line = line_number(
|
||||
self.main_source, '// Set breakpoint here.')
|
||||
|
||||
@skipUnlessDarwin
|
||||
@add_test_categories(['pyapi'])
|
||||
def test_with_python_api(self):
|
||||
"""Test calling methods on super."""
|
||||
|
||||
@ -1,5 +1,4 @@
|
||||
from lldbsuite.test import lldbinline
|
||||
from lldbsuite.test import decorators
|
||||
|
||||
lldbinline.MakeInlineTest(
|
||||
__file__, globals(), [decorators.skipUnlessDarwin])
|
||||
__file__, globals(), [])
|
||||
|
||||
@ -6,7 +6,6 @@ from lldbsuite.test import lldbutil
|
||||
class TestOrderedSet(TestBase):
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@skipUnlessDarwin
|
||||
def test_ordered_set(self):
|
||||
self.build()
|
||||
src_file = "main.m"
|
||||
|
||||
@ -11,7 +11,6 @@ from lldbsuite.test.lldbtest import *
|
||||
from lldbsuite.test import lldbutil
|
||||
|
||||
|
||||
@skipUnlessDarwin
|
||||
class PrintObjTestCase(TestBase):
|
||||
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@ -14,7 +14,6 @@ class TestPtrRefsObjC(TestBase):
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@skipIfAsan # The output looks different under ASAN.
|
||||
@skipUnlessDarwin
|
||||
def test_ptr_refs(self):
|
||||
"""Test the ptr_refs tool on Darwin with Objective-C"""
|
||||
self.build()
|
||||
|
||||
@ -10,7 +10,6 @@ from lldbsuite.test.lldbtest import *
|
||||
from lldbsuite.test import lldbutil
|
||||
|
||||
|
||||
@skipUnlessDarwin
|
||||
class MethodReturningBOOLTestCase(TestBase):
|
||||
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@ -10,7 +10,6 @@ from lldbsuite.test.lldbtest import *
|
||||
from lldbsuite.test import lldbutil
|
||||
|
||||
|
||||
@skipUnlessDarwin
|
||||
class Rdar10967107TestCase(TestBase):
|
||||
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@ -10,7 +10,6 @@ from lldbsuite.test.lldbtest import *
|
||||
from lldbsuite.test import lldbutil
|
||||
|
||||
|
||||
@skipUnlessDarwin
|
||||
class Rdar10967107TestCase(TestBase):
|
||||
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@ -15,7 +15,6 @@ from lldbsuite.test import lldbutil
|
||||
# test if WindowServer isn't available.
|
||||
# Note: Simply applying the @skipIf decorator here confuses the test harness
|
||||
# and gives a spurious failure.
|
||||
@skipUnlessDarwin
|
||||
class Rdar12408181TestCase(TestBase):
|
||||
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@ -12,7 +12,6 @@ class TestRealDefinition(TestBase):
|
||||
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@skipUnlessDarwin
|
||||
def test_frame_var_after_stop_at_interface(self):
|
||||
"""Test that we can find the implementation for an objective C type"""
|
||||
if self.getArchitecture() == 'i386':
|
||||
@ -50,7 +49,6 @@ class TestRealDefinition(TestBase):
|
||||
"(NSString *)",
|
||||
"foo->_bar->_hidden_ivar = 0x"])
|
||||
|
||||
@skipUnlessDarwin
|
||||
def test_frame_var_after_stop_at_implementation(self):
|
||||
"""Test that we can find the implementation for an objective C type"""
|
||||
if self.getArchitecture() == 'i386':
|
||||
|
||||
@ -11,7 +11,6 @@ class ObjCSelfTestCase(TestBase):
|
||||
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@skipUnlessDarwin
|
||||
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()
|
||||
|
||||
@ -21,7 +21,6 @@ class ObjCSingleEntryDictionaryTestCase(TestBase):
|
||||
# Find the line number to break inside main().
|
||||
self.line = line_number('main.m', '// break here')
|
||||
|
||||
@skipUnlessDarwin
|
||||
@expectedFailureAll(oslist=['watchos'], bugnumber="rdar://problem/34642736") # bug in NSDictionary formatting on watchos
|
||||
def test_single_entry_dict(self):
|
||||
self.build()
|
||||
|
||||
@ -1,6 +1,4 @@
|
||||
from lldbsuite.test import lldbinline
|
||||
from lldbsuite.test import decorators
|
||||
|
||||
lldbinline.MakeInlineTest(
|
||||
__file__, globals(), [
|
||||
decorators.skipUnlessDarwin])
|
||||
__file__, globals(), [])
|
||||
|
||||
@ -1,5 +1,3 @@
|
||||
from lldbsuite.test import lldbinline
|
||||
from lldbsuite.test import decorators
|
||||
|
||||
lldbinline.MakeInlineTest(
|
||||
__file__, globals(), [decorators.skipUnlessDarwin])
|
||||
lldbinline.MakeInlineTest(__file__, globals(), [])
|
||||
|
||||
1
lldb/test/API/lang/objcxx/.categories
Normal file
1
lldb/test/API/lang/objcxx/.categories
Normal file
@ -0,0 +1 @@
|
||||
objc
|
||||
@ -1,5 +1,4 @@
|
||||
from lldbsuite.test import decorators
|
||||
from lldbsuite.test import lldbinline
|
||||
|
||||
lldbinline.MakeInlineTest(
|
||||
__file__, globals(), [decorators.skipUnlessDarwin])
|
||||
lldbinline.MakeInlineTest(__file__, globals(), [])
|
||||
|
||||
@ -7,7 +7,6 @@ class TestObjCXXBridgedPO(TestBase):
|
||||
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@skipUnlessDarwin
|
||||
def test_bridged_type_po(self):
|
||||
self.build()
|
||||
lldbutil.run_to_source_breakpoint(
|
||||
|
||||
@ -9,7 +9,6 @@ class TestObjCXXHideRuntimeSupportValues(TestBase):
|
||||
|
||||
mydir = TestBase.compute_mydir(__file__)
|
||||
|
||||
@skipUnlessDarwin
|
||||
def test_hide_runtime_support_values(self):
|
||||
self.build()
|
||||
_, process, _, _ = lldbutil.run_to_source_breakpoint(
|
||||
|
||||
@ -1,5 +1,4 @@
|
||||
from lldbsuite.test import decorators
|
||||
from lldbsuite.test import lldbinline
|
||||
|
||||
lldbinline.MakeInlineTest(
|
||||
__file__, globals(), [decorators.skipUnlessDarwin])
|
||||
lldbinline.MakeInlineTest(__file__, globals(), [])
|
||||
|
||||
1
lldb/test/API/macosx/nslog/.categories
Normal file
1
lldb/test/API/macosx/nslog/.categories
Normal file
@ -0,0 +1 @@
|
||||
objc
|
||||
@ -19,8 +19,7 @@ class ObjCSBTypeTestCase(TestBase):
|
||||
TestBase.setUp(self)
|
||||
self.line = line_number("main.m", '// Break at this line')
|
||||
|
||||
@skipUnlessDarwin
|
||||
@add_test_categories(['pyapi'])
|
||||
@add_test_categories(['objc', 'pyapi'])
|
||||
def test(self):
|
||||
"""Test SBType for ObjC classes."""
|
||||
self.build()
|
||||
|
||||
@ -3,7 +3,7 @@ from lldbsuite.test import lldbinline
|
||||
|
||||
lldbinline.MakeInlineTest(
|
||||
__file__, globals(), [
|
||||
decorators.skipUnlessDarwin,
|
||||
decorators.add_test_categories(["objc"]),
|
||||
decorators.expectedFailureAll(
|
||||
oslist=['macosx'], archs=['i386'],
|
||||
bugnumber='rdar://28656677')])
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user