diff options
author | Ran Benita <ran@unusedvar.com> | 2020-05-01 14:40:16 +0300 |
---|---|---|
committer | Ran Benita <ran@unusedvar.com> | 2020-06-05 11:34:20 +0300 |
commit | 71dfdca4df6961460653c265026e194fbcaebef2 (patch) | |
tree | c6a88af4e3c29addc5fd95fd01ae36a3ef5fbfb4 /src/_pytest/pytester.py | |
parent | 848ab00663c9daf8cd27ee92dec1005cd9633152 (diff) | |
download | pytest-71dfdca4df6961460653c265026e194fbcaebef2.tar.gz |
Enable check_untyped_defs mypy option for src/
This option checks even functions which are not annotated. It's a good
step to ensure that existing type annotation are correct.
In a Pareto fashion, the last few holdouts are always the ugliest,
beware.
Diffstat (limited to 'src/_pytest/pytester.py')
-rw-r--r-- | src/_pytest/pytester.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/_pytest/pytester.py b/src/_pytest/pytester.py index 60df17b90..754ecc10f 100644 --- a/src/_pytest/pytester.py +++ b/src/_pytest/pytester.py @@ -1169,8 +1169,10 @@ class Testdir: popen = subprocess.Popen(cmdargs, stdout=stdout, stderr=stderr, **kw) if stdin is Testdir.CLOSE_STDIN: + assert popen.stdin is not None popen.stdin.close() elif isinstance(stdin, bytes): + assert popen.stdin is not None popen.stdin.write(stdin) return popen |