Skip tests when compiler with older versions of clang
authorAdrian Prantl <aprantl@apple.com>
Fri, 19 Nov 2021 17:05:38 +0000 (09:05 -0800)
committerAdrian Prantl <aprantl@apple.com>
Fri, 19 Nov 2021 17:05:48 +0000 (09:05 -0800)
lldb/test/API/commands/expression/import-std-module/unique_ptr/TestUniquePtrFromStdModule.py
lldb/test/API/functionalities/mtc/simple/TestMTCSimple.py
lldb/test/API/lang/objc/modules-compile-error/TestModulesCompileError.py
lldb/test/API/tools/lldb-server/TestLldbGdbServer.py

index 878315b..f8e1aa7 100644 (file)
@@ -13,6 +13,7 @@ class TestUniquePtr(TestBase):
 
     @add_test_categories(["libc++"])
     @skipIf(compiler=no_match("clang"))
+    @skipIf(compiler="clang", compiler_version=['<', '9.0'])
     @skipIfLinux # s.reset() causes link errors on ubuntu 18.04/Clang 9
     def test(self):
         self.build()
index 23fe72e..a4deb96 100644 (file)
@@ -15,6 +15,7 @@ class MTCSimpleTestCase(TestBase):
     mydir = TestBase.compute_mydir(__file__)
 
     @skipUnlessDarwin
+    @skipIf(compiler="clang", compiler_version=['<', '9.0'])
     def test(self):
         self.mtc_dylib_path = findMainThreadCheckerDylib()
         if self.mtc_dylib_path == "":
@@ -24,6 +25,7 @@ class MTCSimpleTestCase(TestBase):
         self.mtc_tests()
 
     @skipIf(archs=['i386'])
+    @skipIf(compiler="clang", compiler_version=['<', '9.0'])
     def mtc_tests(self):
         self.assertNotEqual(self.mtc_dylib_path, "")
 
index 610d001..36cf050 100644 (file)
@@ -7,6 +7,7 @@ class TestCase(TestBase):
 
     mydir = TestBase.compute_mydir(__file__)
 
+    @skipIf(compiler="clang", compiler_version=['<', '11.0'])
     def test(self):
         self.build()
         lldbutil.run_to_source_breakpoint(self, "// break here", lldb.SBFileSpec("main.m"))
index 2f76654..01ae242 100644 (file)
@@ -390,12 +390,14 @@ class LldbGdbServerTestCase(gdbremote_testcase.GdbRemoteTestCaseBase, DwarfOpcod
             self.assertEqual(int(context.get("thread_id"), 16), thread)
 
     @expectedFailureAll(oslist=["windows"]) # expect 4 threads
+    @skipIf(compiler="clang", compiler_version=['<', '11.0'])
     def test_Hg_switches_to_3_threads_launch(self):
         self.build()
         self.set_inferior_startup_launch()
         self.Hg_switches_to_3_threads()
 
     @expectedFailureAll(oslist=["windows"]) # expecting one more thread
+    @skipIf(compiler="clang", compiler_version=['<', '11.0'])
     def test_Hg_switches_to_3_threads_attach(self):
         self.build()
         self.set_inferior_startup_attach()
@@ -403,6 +405,7 @@ class LldbGdbServerTestCase(gdbremote_testcase.GdbRemoteTestCaseBase, DwarfOpcod
 
     @expectedFailureAll(oslist=["windows"]) # expect 4 threads
     @add_test_categories(["llgs"])
+    @skipIf(compiler="clang", compiler_version=['<', '11.0'])
     def test_Hg_switches_to_3_threads_attach_pass_correct_pid(self):
         self.build()
         self.set_inferior_startup_attach()