summaryrefslogtreecommitdiff
path: root/src/_pytest/terminal.py
diff options
context:
space:
mode:
authorRan Benita <ran@unusedvar.com>2020-08-01 13:06:13 +0300
committerRan Benita <ran@unusedvar.com>2020-08-01 20:39:15 +0300
commitbe656dd4e4444acd9600660fc3b6bf3896067dbe (patch)
treeea7998a38648f2397a818ad8f9948d2048e3b631 /src/_pytest/terminal.py
parent49827adcb9256c9c9c06a25729421dcc3c385edc (diff)
downloadpytest-be656dd4e4444acd9600660fc3b6bf3896067dbe.tar.gz
typing: set disallow_any_generics
This prevents referring to a generic type without filling in its generic type parameters. The FixtureDef typing might need some more refining in the future.
Diffstat (limited to 'src/_pytest/terminal.py')
-rw-r--r--src/_pytest/terminal.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/_pytest/terminal.py b/src/_pytest/terminal.py
index 86c327226..cb58f5595 100644
--- a/src/_pytest/terminal.py
+++ b/src/_pytest/terminal.py
@@ -319,7 +319,7 @@ class TerminalReporter:
self.stats = {} # type: Dict[str, List[Any]]
self._main_color = None # type: Optional[str]
- self._known_types = None # type: Optional[List]
+ self._known_types = None # type: Optional[List[str]]
self.startdir = config.invocation_dir
if file is None:
file = sys.stdout
@@ -469,7 +469,7 @@ class TerminalReporter:
def line(self, msg: str, **kw: bool) -> None:
self._tw.line(msg, **kw)
- def _add_stats(self, category: str, items: Sequence) -> None:
+ def _add_stats(self, category: str, items: Sequence[Any]) -> None:
set_main_color = category not in self.stats
self.stats.setdefault(category, []).extend(items)
if set_main_color: