From 63ce288cf3bf328e81087619815f141e3e55ffa6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Br=C3=A9nainn=20Woodsend?= Date: Sun, 8 Oct 2023 21:54:42 +0100 Subject: [PATCH] Run tests verbosely by default. --- polycotylus/_docker.py | 2 +- tests/test_docker.py | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/polycotylus/_docker.py b/polycotylus/_docker.py index 65b9f0e..2d99436 100644 --- a/polycotylus/_docker.py +++ b/polycotylus/_docker.py @@ -234,7 +234,7 @@ def lazy_run(base, command, **kwargs): def _verbosity(): - return int(os.environ.get("POLYCOTYLUS_VERBOSITY", 0)) + return int(os.environ.get("POLYCOTYLUS_VERBOSITY", 2)) class Error(Exception): diff --git a/tests/test_docker.py b/tests/test_docker.py index ea4aad1..53519a9 100644 --- a/tests/test_docker.py +++ b/tests/test_docker.py @@ -166,7 +166,8 @@ def test_verbosity(monkeypatch, capsys, tmp_path): monkeypatch.delenv("POLYCOTYLUS_VERBOSITY") run() - assert capsys.readouterr().out == "" + out = capsys.readouterr().out + assert output_re.findall(out) _docker.build("Dockerfile", tmp_path, verbosity=1) out = capsys.readouterr().out