# HG changeset patch # User Mads Kiilerich # Date 1395184794 -3600 # Node ID 805a5c2fe9c8087a1ef536510afbda93a8c5d45a # Parent a9e00192f30adea3646474ef41ec227926acc0a2 tests: small refactoring of run-tests' handling of tests list [ original upstream message ] diff -r a9e00192f30a -r 805a5c2fe9c8 tests/run-tests.py --- a/tests/run-tests.py Wed Mar 19 02:45:14 2014 +0100 +++ b/tests/run-tests.py Wed Mar 19 00:19:54 2014 +0100 @@ -1180,12 +1180,12 @@ checktools() - if len(args) == 0: - args = [t for t in os.listdir(".") - if t.startswith("test-") - and (t.endswith(".py") or t.endswith(".t"))] + if not args: + args = os.listdir(".") - tests = args + tests = [t for t in args + if t.startswith("test-") + and (t.endswith(".py") or t.endswith(".t"))] if options.random: random.shuffle(tests)