python3-stdio-mgr

Context manager for mocking/wrapping stdin/stdout/stderr

Description

This library offers a context manager for mocking and wrapping standard input, output, and error streams. It simplifies capturing and testing console inputs and outputs within Python applications. Unlike the standard library's contextlib, this tool provides a more concise way to handle stdin, stdout, and stderr simultaneously, making it particularly useful for managing user inputs and outputs in a controlled environment. Standard input can be pre-loaded or appended during the managed context, which allows for flexible and precise simulation of user interactions. Additionally, the library supports wrapping functions that generate output, enabling the modification of internal print calls within those functions.

Upload more screenshots

Please help extend the collection of screenshots. Just make a screenshot and upload it here. You don't need to register or anything.

Upload a screenshot

Hint: upload an image here from your clipboard with Ctrl-V


Homepage

https://github.com/bskinn/stdio-mgr


Install this software package

If the package is available for the distribution you are currently using on your computer then install the software by clicking on…

Install python3-stdio-mgr