1515from utils import colored , get_mypy_req , make_venv , print_error , print_success_msg
1616
1717
18- def run_stubtest (dist : Path , * , verbose : bool = False , specified_stubs_only : bool = False ) -> bool :
18+ def run_stubtest (dist : Path , * , verbose : bool = False , specified_platforms_only : bool = False ) -> bool :
1919 dist_name = dist .name
2020 metadata = read_metadata (dist_name )
2121 print (f"{ dist_name } ... " , end = "" )
@@ -26,7 +26,7 @@ def run_stubtest(dist: Path, *, verbose: bool = False, specified_stubs_only: boo
2626 return True
2727
2828 if sys .platform not in stubtest_settings .platforms :
29- if specified_stubs_only :
29+ if specified_platforms_only :
3030 print (colored ("skipping (platform not specified in METADATA.toml)" , "yellow" ))
3131 return True
3232 print (colored (f"Note: { dist_name } is not currently tested on { sys .platform } in typeshed's CI." , "yellow" ))
@@ -154,7 +154,7 @@ def main() -> NoReturn:
154154 parser .add_argument ("--num-shards" , type = int , default = 1 )
155155 parser .add_argument ("--shard-index" , type = int , default = 0 )
156156 parser .add_argument (
157- "--specified-stubs -only" ,
157+ "--specified-platforms -only" ,
158158 action = "store_true" ,
159159 help = "skip the test if the current platform is not specified in METADATA.toml/tool.stubtest.platforms" ,
160160 )
@@ -171,7 +171,7 @@ def main() -> NoReturn:
171171 for i , dist in enumerate (dists ):
172172 if i % args .num_shards != args .shard_index :
173173 continue
174- if not run_stubtest (dist , verbose = args .verbose , specified_stubs_only = args .specified_stubs_only ):
174+ if not run_stubtest (dist , verbose = args .verbose , specified_platforms_only = args .specified_platforms_only ):
175175 result = 1
176176 sys .exit (result )
177177
0 commit comments