77 FileType ,
88)
99from collections import namedtuple
10+ from collections .abc import (
11+ Generator ,
12+ Iterable ,
13+ )
1014from typing import (
1115 Any ,
1216 Dict ,
13- Generator ,
14- Iterable ,
1517 TextIO ,
1618)
1719
2729)
2830
2931
30- def skipped_test_from (obj : Dict [str , Any ]) -> Test :
32+ def skipped_test_from (obj : dict [str , Any ]) -> Test :
3133 for stage in ("setup" , "call" , "teardown" ):
3234 try :
3335 filename , _ , details = eval (obj [stage ]["longrepr" ])
@@ -74,7 +76,7 @@ def _human(tests: Iterable[Test], output: TextIO) -> None:
7476def _csv (tests : Iterable [Test ], output : TextIO ) -> None :
7577 fields = ("test-case" , "status" , "details" )
7678
77- def test_to_entry (t : Test ) -> Dict [str , Any ]:
79+ def test_to_entry (t : Test ) -> dict [str , Any ]:
7880 return {
7981 "test-case" : t .nodeid ,
8082 "status" : t .outcome ,
@@ -88,7 +90,7 @@ def test_to_entry(t: Test) -> Dict[str, Any]:
8890
8991
9092def main (
91- test_results : str , output : TextIO , format : str , ** kwargs : Dict [str , Any ]
93+ test_results : str , output : TextIO , format : str , ** kwargs : dict [str , Any ]
9294) -> int :
9395 skipped_tests = all_skipped_tests (test_results )
9496 dispatcher = {"human" : _human , "csv" : _csv }
0 commit comments