File tree Expand file tree Collapse file tree 2 files changed +9
-0
lines changed
Expand file tree Collapse file tree 2 files changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -260,6 +260,8 @@ def main():
260260
261261 # Run each test case with each type checker.
262262 for type_checker in TYPE_CHECKERS :
263+ if options .only_run and options .only_run != type_checker .name :
264+ continue
263265 if not type_checker .install ():
264266 print (f"Skipping tests for { type_checker .name } " )
265267 else :
Original file line number Diff line number Diff line change 55import argparse
66from dataclasses import dataclass
77
8+ from type_checker import TYPE_CHECKERS
89
910@dataclass
1011class _Options :
1112 report_only : bool | None
13+ only_run : str | None
1214
1315
1416def parse_options (argv : list [str ]) -> _Options :
@@ -19,5 +21,10 @@ def parse_options(argv: list[str]) -> _Options:
1921 action = "store_true" ,
2022 help = "regenerates the test suite report from past results" ,
2123 )
24+ reporting_group .add_argument (
25+ "--only-run" ,
26+ help = "Only runs the type checker" ,
27+ choices = [tc .name for tc in TYPE_CHECKERS ]
28+ )
2229 ret = _Options (** vars (parser .parse_args (argv )))
2330 return ret
You can’t perform that action at this time.
0 commit comments