Show More
@@ -90,6 +90,8 b' def parseargs():' | |||
|
90 | 90 | parser.add_option("-j", "--jobs", type="int", |
|
91 | 91 | help="number of jobs to run in parallel" |
|
92 | 92 | " (default: $%s or %d)" % defaults['jobs']) |
|
93 | parser.add_option("-k", "--keywords", | |
|
94 | help="run tests matching keywords") | |
|
93 | 95 | parser.add_option("--keep-tmpdir", action="store_true", |
|
94 | 96 | help="keep temporary directory after running tests" |
|
95 | 97 | " (best used with --tmpdir)") |
@@ -688,10 +690,21 b' def runtests(options, tests):' | |||
|
688 | 690 | |
|
689 | 691 | skips = [] |
|
690 | 692 | fails = [] |
|
693 | ||
|
691 | 694 | for test in tests: |
|
692 | 695 | if options.retest and not os.path.exists(test + ".err"): |
|
693 | 696 | skipped += 1 |
|
694 | 697 | continue |
|
698 | ||
|
699 | if options.keywords: | |
|
700 | t = open(test).read().lower() + test.lower() | |
|
701 | for k in options.keywords.lower().split(): | |
|
702 | if k in t: | |
|
703 | break | |
|
704 | else: | |
|
705 | skipped +=1 | |
|
706 | continue | |
|
707 | ||
|
695 | 708 | ret = runone(options, test, skips, fails) |
|
696 | 709 | if ret is None: |
|
697 | 710 | skipped += 1 |
General Comments 0
You need to be logged in to leave comments.
Login now