()
| 54 | |
| 55 | |
| 56 | def test_install_max_depth() -> None: |
| 57 | console = Console(file=io.StringIO()) |
| 58 | dh = sys.displayhook |
| 59 | install(console, max_depth=1) |
| 60 | sys.displayhook({"foo": {"bar": True}}) |
| 61 | assert console.file.getvalue() == "{'foo': {...}}\n" |
| 62 | assert sys.displayhook is not dh |
| 63 | |
| 64 | |
| 65 | def test_ipy_display_hook__repr_html() -> None: |