Skip to content
Myr

Merge pull request #1794 from MLH-Fellowship/fix-clirunner-isolation

Before adoption: this commit came in with the history the project adopted, so no landing records it.

CliRunner.isolation() returns type compatible with CliRunner.invoke()

authored by David Lord · committed by GitHub · parents 1b1578d, 24c6b8a · Browse files · 1 file+2 added−1 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+2 added−1 removed

  • other:+2 added−1 removed

1 file+2 added−1 removed

modified:src/click/testing.py+2 added-1 removed
206 unmodified lines
207 sys.stdout = _NamedTextIOWrapper(208 bytes_output, encoding=self.charset, name="<stdout>", mode="w"209 )210211 bytes_error = None212 if self.mix_stderr:213 sys.stderr = sys.stdout214 else:215 bytes_error = io.BytesIO()
46 unmodified lines
262 except Exception:263 pass264 else:265 os.environ[key] = value265 yield (bytes_output, not self.mix_stderr and bytes_error)266 yield (bytes_output, bytes_error)267 finally:268 for key, value in old_env.items():269 if value is None:270 try:
140 unmodified lines