[Lldb-commits] [lldb] r369995 - [dotest] Remove long running test "decorator" and re-enable tests.

Jonas Devlieghere via lldb-commits lldb-commits at lists.llvm.org
Mon Aug 26 17:18:23 PDT 2019


Author: jdevlieghere
Date: Mon Aug 26 17:18:22 2019
New Revision: 369995

URL: http://llvm.org/viewvc/llvm-project?rev=369995&view=rev
Log:
[dotest] Remove long running test "decorator" and re-enable tests.

Today I discovered the skipLongRunningTest decorator and to my surprise
all the tests were passing without the decorator. They don't seem to be
that expensive either, they take a few seconds but we have tests that
take much longer than that. As such I propose to remove the decorator
and enable them by default.

Differential revision: https://reviews.llvm.org/D66774

Modified:
    lldb/trunk/packages/Python/lldbsuite/test/configuration.py
    lldb/trunk/packages/Python/lldbsuite/test/dotest.py
    lldb/trunk/packages/Python/lldbsuite/test/dotest_args.py
    lldb/trunk/packages/Python/lldbsuite/test/functionalities/thread/concurrent_events/TestConcurrentManyBreakpoints.py
    lldb/trunk/packages/Python/lldbsuite/test/functionalities/thread/concurrent_events/TestConcurrentManyCrash.py
    lldb/trunk/packages/Python/lldbsuite/test/functionalities/thread/concurrent_events/TestConcurrentManySignals.py
    lldb/trunk/packages/Python/lldbsuite/test/functionalities/thread/concurrent_events/TestConcurrentManyWatchpoints.py
    lldb/trunk/packages/Python/lldbsuite/test/functionalities/unwind/standard/TestStandardUnwind.py
    lldb/trunk/packages/Python/lldbsuite/test/lang/cpp/stl/TestStdCXXDisassembly.py
    lldb/trunk/packages/Python/lldbsuite/test/lang/objc/foundation/TestFoundationDisassembly.py
    lldb/trunk/packages/Python/lldbsuite/test/lldbtest.py

Modified: lldb/trunk/packages/Python/lldbsuite/test/configuration.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/packages/Python/lldbsuite/test/configuration.py?rev=369995&r1=369994&r2=369995&view=diff
==============================================================================
--- lldb/trunk/packages/Python/lldbsuite/test/configuration.py (original)
+++ lldb/trunk/packages/Python/lldbsuite/test/configuration.py Mon Aug 26 17:18:22 2019
@@ -57,9 +57,6 @@ cflags_extras = ''
 # The filters (testclass.testmethod) used to admit tests into our test suite.
 filters = []
 
-# By default, we skip long running test case.  Use '-l' option to override.
-skip_long_running_test = True
-
 # Parsable mode silences headers, and any other output this script might generate, and instead
 # prints machine-readable output similar to what clang tests produce.
 parsable = False

Modified: lldb/trunk/packages/Python/lldbsuite/test/dotest.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/packages/Python/lldbsuite/test/dotest.py?rev=369995&r1=369994&r2=369995&view=diff
==============================================================================
--- lldb/trunk/packages/Python/lldbsuite/test/dotest.py (original)
+++ lldb/trunk/packages/Python/lldbsuite/test/dotest.py Mon Aug 26 17:18:22 2019
@@ -367,9 +367,6 @@ def parseOptionsAndInitTestdirs():
             usage(parser)
         configuration.filters.extend(args.f)
 
-    if args.l:
-        configuration.skip_long_running_test = False
-
     if args.framework:
         configuration.lldbFrameworkPath = args.framework
 
@@ -1143,10 +1140,6 @@ def run_suite():
 
     setupSysPath()
 
-    #
-    # If '-l' is specified, do not skip the long running tests.
-    if not configuration.skip_long_running_test:
-        os.environ["LLDB_SKIP_LONG_RUNNING_TEST"] = "NO"
 
     # For the time being, let's bracket the test runner within the
     # lldb.SBDebugger.Initialize()/Terminate() pair.

Modified: lldb/trunk/packages/Python/lldbsuite/test/dotest_args.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/packages/Python/lldbsuite/test/dotest_args.py?rev=369995&r1=369994&r2=369995&view=diff
==============================================================================
--- lldb/trunk/packages/Python/lldbsuite/test/dotest_args.py (original)
+++ lldb/trunk/packages/Python/lldbsuite/test/dotest_args.py Mon Aug 26 17:18:22 2019
@@ -84,7 +84,6 @@ def create_parser():
         metavar='filterspec',
         action='append',
         help='Specify a filter, which consists of the test class name, a dot, followed by the test method, to only admit such test into the test suite')  # FIXME: Example?
-    X('-l', "Don't skip long running tests")
     group.add_argument(
         '-p',
         metavar='pattern',

Modified: lldb/trunk/packages/Python/lldbsuite/test/functionalities/thread/concurrent_events/TestConcurrentManyBreakpoints.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/packages/Python/lldbsuite/test/functionalities/thread/concurrent_events/TestConcurrentManyBreakpoints.py?rev=369995&r1=369994&r2=369995&view=diff
==============================================================================
--- lldb/trunk/packages/Python/lldbsuite/test/functionalities/thread/concurrent_events/TestConcurrentManyBreakpoints.py (original)
+++ lldb/trunk/packages/Python/lldbsuite/test/functionalities/thread/concurrent_events/TestConcurrentManyBreakpoints.py Mon Aug 26 17:18:22 2019
@@ -12,9 +12,6 @@ class ConcurrentManyBreakpoints(Concurre
 
     mydir = ConcurrentEventsBase.compute_mydir(__file__)
 
-    @unittest2.skipIf(
-        TestBase.skipLongRunningTest(),
-        "Skip this long running test")
     # Atomic sequences are not supported yet for MIPS in LLDB.
     @skipIf(triple='^mips')
     def test(self):

Modified: lldb/trunk/packages/Python/lldbsuite/test/functionalities/thread/concurrent_events/TestConcurrentManyCrash.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/packages/Python/lldbsuite/test/functionalities/thread/concurrent_events/TestConcurrentManyCrash.py?rev=369995&r1=369994&r2=369995&view=diff
==============================================================================
--- lldb/trunk/packages/Python/lldbsuite/test/functionalities/thread/concurrent_events/TestConcurrentManyCrash.py (original)
+++ lldb/trunk/packages/Python/lldbsuite/test/functionalities/thread/concurrent_events/TestConcurrentManyCrash.py Mon Aug 26 17:18:22 2019
@@ -12,9 +12,6 @@ class ConcurrentManyCrash(ConcurrentEven
 
     mydir = ConcurrentEventsBase.compute_mydir(__file__)
 
-    @unittest2.skipIf(
-        TestBase.skipLongRunningTest(),
-        "Skip this long running test")
     # Atomic sequences are not supported yet for MIPS in LLDB.
     @skipIf(triple='^mips')
     def test(self):

Modified: lldb/trunk/packages/Python/lldbsuite/test/functionalities/thread/concurrent_events/TestConcurrentManySignals.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/packages/Python/lldbsuite/test/functionalities/thread/concurrent_events/TestConcurrentManySignals.py?rev=369995&r1=369994&r2=369995&view=diff
==============================================================================
--- lldb/trunk/packages/Python/lldbsuite/test/functionalities/thread/concurrent_events/TestConcurrentManySignals.py (original)
+++ lldb/trunk/packages/Python/lldbsuite/test/functionalities/thread/concurrent_events/TestConcurrentManySignals.py Mon Aug 26 17:18:22 2019
@@ -12,9 +12,6 @@ class ConcurrentManySignals(ConcurrentEv
 
     mydir = ConcurrentEventsBase.compute_mydir(__file__)
 
-    @unittest2.skipIf(
-        TestBase.skipLongRunningTest(),
-        "Skip this long running test")
     # Atomic sequences are not supported yet for MIPS in LLDB.
     @skipIf(triple='^mips')
     def test(self):

Modified: lldb/trunk/packages/Python/lldbsuite/test/functionalities/thread/concurrent_events/TestConcurrentManyWatchpoints.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/packages/Python/lldbsuite/test/functionalities/thread/concurrent_events/TestConcurrentManyWatchpoints.py?rev=369995&r1=369994&r2=369995&view=diff
==============================================================================
--- lldb/trunk/packages/Python/lldbsuite/test/functionalities/thread/concurrent_events/TestConcurrentManyWatchpoints.py (original)
+++ lldb/trunk/packages/Python/lldbsuite/test/functionalities/thread/concurrent_events/TestConcurrentManyWatchpoints.py Mon Aug 26 17:18:22 2019
@@ -12,9 +12,6 @@ class ConcurrentManyWatchpoints(Concurre
 
     mydir = ConcurrentEventsBase.compute_mydir(__file__)
 
-    @unittest2.skipIf(
-        TestBase.skipLongRunningTest(),
-        "Skip this long running test")
     # Atomic sequences are not supported yet for MIPS in LLDB.
     @skipIf(triple='^mips')
     @add_test_categories(["watchpoint"])

Modified: lldb/trunk/packages/Python/lldbsuite/test/functionalities/unwind/standard/TestStandardUnwind.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/packages/Python/lldbsuite/test/functionalities/unwind/standard/TestStandardUnwind.py?rev=369995&r1=369994&r2=369995&view=diff
==============================================================================
--- lldb/trunk/packages/Python/lldbsuite/test/functionalities/unwind/standard/TestStandardUnwind.py (original)
+++ lldb/trunk/packages/Python/lldbsuite/test/functionalities/unwind/standard/TestStandardUnwind.py Mon Aug 26 17:18:22 2019
@@ -145,9 +145,6 @@ for d in test_source_dirs:
 for f in test_source_files:
     if f.endswith(".cpp") or f.endswith(".c"):
         @add_test_categories(["dwarf"])
-        @unittest2.skipIf(
-            TestBase.skipLongRunningTest(),
-            "Skip this long running test")
         def test_function_dwarf(self, f=f):
             if f.endswith(".cpp"):
                 d = {'CXX_SOURCES': f}

Modified: lldb/trunk/packages/Python/lldbsuite/test/lang/cpp/stl/TestStdCXXDisassembly.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/packages/Python/lldbsuite/test/lang/cpp/stl/TestStdCXXDisassembly.py?rev=369995&r1=369994&r2=369995&view=diff
==============================================================================
--- lldb/trunk/packages/Python/lldbsuite/test/lang/cpp/stl/TestStdCXXDisassembly.py (original)
+++ lldb/trunk/packages/Python/lldbsuite/test/lang/cpp/stl/TestStdCXXDisassembly.py Mon Aug 26 17:18:22 2019
@@ -22,11 +22,6 @@ class StdCXXDisassembleTestCase(TestBase
         # Find the line number to break inside main().
         self.line = line_number('main.cpp', '// Set break point at this line.')
 
-    # rdar://problem/8504895
-    # Crash while doing 'disassemble -n "-[NSNumber descriptionWithLocale:]"
-    @unittest2.skipIf(
-        TestBase.skipLongRunningTest(),
-        "Skip this long running test")
     def test_stdcxx_disasm(self):
         """Do 'disassemble' on each and every 'Code' symbol entry from the std c++ lib."""
         self.build()

Modified: lldb/trunk/packages/Python/lldbsuite/test/lang/objc/foundation/TestFoundationDisassembly.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/packages/Python/lldbsuite/test/lang/objc/foundation/TestFoundationDisassembly.py?rev=369995&r1=369994&r2=369995&view=diff
==============================================================================
--- lldb/trunk/packages/Python/lldbsuite/test/lang/objc/foundation/TestFoundationDisassembly.py (original)
+++ lldb/trunk/packages/Python/lldbsuite/test/lang/objc/foundation/TestFoundationDisassembly.py Mon Aug 26 17:18:22 2019
@@ -18,11 +18,6 @@ class FoundationDisassembleTestCase(Test
 
     mydir = TestBase.compute_mydir(__file__)
 
-    # rdar://problem/8504895
-    # Crash while doing 'disassemble -n "-[NSNumber descriptionWithLocale:]"
-    @unittest2.skipIf(
-        TestBase.skipLongRunningTest(),
-        "Skip this long running test")
     def test_foundation_disasm(self):
         """Do 'disassemble -n func' on each and every 'Code' symbol entry from the Foundation.framework."""
         self.build()

Modified: lldb/trunk/packages/Python/lldbsuite/test/lldbtest.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/packages/Python/lldbsuite/test/lldbtest.py?rev=369995&r1=369994&r2=369995&view=diff
==============================================================================
--- lldb/trunk/packages/Python/lldbsuite/test/lldbtest.py (original)
+++ lldb/trunk/packages/Python/lldbsuite/test/lldbtest.py Mon Aug 26 17:18:22 2019
@@ -560,18 +560,6 @@ class Base(unittest2.TestCase):
             print("Restore dir to:", cls.oldcwd, file=sys.stderr)
         os.chdir(cls.oldcwd)
 
-    @classmethod
-    def skipLongRunningTest(cls):
-        """
-        By default, we skip long running test case.
-        This can be overridden by passing '-l' to the test driver (dotest.py).
-        """
-        if "LLDB_SKIP_LONG_RUNNING_TEST" in os.environ and "NO" == os.environ[
-                "LLDB_SKIP_LONG_RUNNING_TEST"]:
-            return False
-        else:
-            return True
-
     def enableLogChannelsForCurrentTest(self):
         if len(lldbtest_config.channels) == 0:
             return




More information about the lldb-commits mailing list