MCPcopy
hub / github.com/treeverse/dvc / test_write

Function test_write

tests/unit/ui/test_console.py:9–18  ·  view source on GitHub ↗

Test that ui.write works.

(capsys)

Source from the content-addressed store, hash-verified

7
8
9def test_write(capsys):
10 """Test that ui.write works."""
11 console = Console(enable=True)
12 message = "hello world"
13 console.write(message)
14 console.error_write(message)
15
16 captured = capsys.readouterr()
17 assert captured.out == f"{message}\n"
18 assert captured.err == f"{message}\n"
19
20
21@pytest.mark.parametrize(

Callers

nothing calls this directly

Calls 3

writeMethod · 0.95
error_writeMethod · 0.95
ConsoleClass · 0.90

Tested by

no test coverage detected