[Lldb-commits] [lldb] r254758 - Fix an issue where all tests marked with skip_if_callable would be skipped regardless of the actual callable

Enrico Granata via lldb-commits lldb-commits at lists.llvm.org
Fri Dec 4 11:50:05 PST 2015


Author: enrico
Date: Fri Dec  4 13:50:05 2015
New Revision: 254758

URL: http://llvm.org/viewvc/llvm-project?rev=254758&view=rev
Log:
Fix an issue where all tests marked with skip_if_callable would be skipped regardless of the actual callable

Modified:
    lldb/trunk/packages/Python/lldbsuite/test/lldbutil.py

Modified: lldb/trunk/packages/Python/lldbsuite/test/lldbutil.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/packages/Python/lldbsuite/test/lldbutil.py?rev=254758&r1=254757&r2=254758&view=diff
==============================================================================
--- lldb/trunk/packages/Python/lldbsuite/test/lldbutil.py (original)
+++ lldb/trunk/packages/Python/lldbsuite/test/lldbutil.py Fri Dec  4 13:50:05 2015
@@ -985,10 +985,11 @@ class PrintableRegex(object):
     def __repr__(self):
         return "re.compile(%s) -> %s" % (self.text, self.regex)
 
-def skip_if_callable(test, callable, reason):
-    if six.callable(test):
-        test.skipTest(reason)
-        return True
+def skip_if_callable(test, mycallable, reason):
+    if six.callable(mycallable):
+        if mycallable(test):
+            test.skipTest(reason)
+            return True
     return False
 
 def skip_if_library_missing(test, target, library):




More information about the lldb-commits mailing list