From 63a9942126abaa8897d143b2cb05dd5b78ece48c Mon Sep 17 00:00:00 2001 From: Arun Babu Neelicattu Date: Sun, 24 Mar 2024 18:06:46 +0100 Subject: [PATCH] ruff: enable flake8-print --- pyproject.toml | 1 + tests/installation/test_executor.py | 2 +- tests/packages/test_locker.py | 1 - 3 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 3213490dd8d..80aa0ae7ed7 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -115,6 +115,7 @@ extend-select = [ "PGH", # pygrep "RUF", # ruff checks "SIM", # flake8-simplify + "T20", # flake8-print "TCH", # flake8-type-checking "TID", # flake8-tidy-imports "UP", # pyupgrade diff --git a/tests/installation/test_executor.py b/tests/installation/test_executor.py index 8a6a6d3141f..e755a03e369 100644 --- a/tests/installation/test_executor.py +++ b/tests/installation/test_executor.py @@ -1426,7 +1426,7 @@ def test_build_system_requires_install_failure( mocker.stopall() # to get real output output = io.fetch_output().strip() - print(output) + assert output.startswith(expected_start) assert output.endswith(expected_end) diff --git a/tests/packages/test_locker.py b/tests/packages/test_locker.py index e54e4d3bd8d..dcf1122b190 100644 --- a/tests/packages/test_locker.py +++ b/tests/packages/test_locker.py @@ -777,7 +777,6 @@ def test_root_extras_dependencies_are_ordered( with locker.lock.open(encoding="utf-8") as f: content = f.read() - print(content) assert content == expected