run-tests: regroup nested functions
authorMatt Mackall <mpm@selenic.com>
Fri, 24 May 2013 13:48:25 -0500
changeset 19244 eee43d763f9f
parent 19243 050c6fae40d2
child 19245 dcb05a1470bd
run-tests: regroup nested functions
tests/run-tests.py
--- a/tests/run-tests.py	Fri May 24 13:47:17 2013 -0500
+++ b/tests/run-tests.py	Fri May 24 13:48:25 2013 -0500
@@ -874,6 +874,11 @@
     def ignore(msg):
         result('i', (test, msg))
 
+    def describe(ret):
+        if ret < 0:
+            return 'killed by signal %d' % -ret
+        return 'returned error code %d' % ret
+
     if not os.path.exists(test):
             skip("doesn't exist")
             return None
@@ -967,11 +972,6 @@
             f.write(line)
         f.close()
 
-    def describe(ret):
-        if ret < 0:
-            return 'killed by signal %d' % -ret
-        return 'returned error code %d' % ret
-
     if skipped:
         mark = 's'
         if out is None:                 # debug mode: nothing to parse