run-tests: filter out non-tests from default list
authorMatt Mackall <mpm@selenic.com>
Fri, 24 May 2013 13:31:44 -0500
changeset 19240 b4ecdc451130
parent 19239 db978c792b02
child 19241 a32986dea31a
run-tests: filter out non-tests from default list
tests/run-tests.py
--- a/tests/run-tests.py	Fri May 24 13:23:19 2013 -0500
+++ b/tests/run-tests.py	Fri May 24 13:31:44 2013 -0500
@@ -1244,7 +1244,9 @@
         checktools()
 
         if len(args) == 0:
-            args = sorted(os.listdir("."))
+            args = sorted(t for t in os.listdir(".")
+                          if t.startswith("test-")
+                          and (t.endswith(".py") or t.endswith(".t")))
 
     tests = args