From e434ad056226858bd18c9e6fd212d8a738adef88 Mon Sep 17 00:00:00 2001 From: p-szafonimateusz Date: Tue, 10 Nov 2026 13:05:42 +0100 Subject: [PATCH] tests: use assert True in the test resources flake8-bugbear 26.11 adds B044, which reports `assert 1` as an assert that is always true, and the flake8 check fails on these test resource files. The tests are meant to always pass, so use `assert True`. Signed-off-by: p-szafonimateusz Assisted-by: Claude Code:claude-opus-5-5 --- tests/resources/tests_collect/test_test1.py | 4 ++-- tests/resources/tests_collect/test_test2.py | 4 ++-- tests/resources/tests_collect/test_test3.py | 6 +++--- tests/resources/tests_collect/test_test4.py | 10 +++++----- tests/resources/tests_dirs/test1/test_testdir1.py | 4 ++-- tests/resources/tests_dirs/test2/test_testdir2.py | 4 ++-- tests/resources/tests_dirs/test2/test_testdir3.py | 4 ++-- .../resources/tests_dirs/test3/test4/test_testdir4.py | 4 ++-- tests/resources/tests_exitcode/test_success.py | 2 +- tests/resources/tests_smp/test_test1.py | 8 ++++---- tests/resources/tests_smp/test_test2.py | 2 +- 11 files changed, 26 insertions(+), 26 deletions(-) diff --git a/tests/resources/tests_collect/test_test1.py b/tests/resources/tests_collect/test_test1.py index fc88501..3eab044 100644 --- a/tests/resources/tests_collect/test_test1.py +++ b/tests/resources/tests_collect/test_test1.py @@ -20,8 +20,8 @@ def test_test1_simple_1(): # pragma: no cover - assert 1 + assert True def test_test1_simple_2(): # pragma: no cover - assert 1 + assert True diff --git a/tests/resources/tests_collect/test_test2.py b/tests/resources/tests_collect/test_test2.py index a4aae5d..8c0bd36 100644 --- a/tests/resources/tests_collect/test_test2.py +++ b/tests/resources/tests_collect/test_test2.py @@ -20,8 +20,8 @@ def test_test2_simple_1(): # pragma: no cover - assert 1 + assert True def test_test2_simple_2(): # pragma: no cover - assert 1 + assert True diff --git a/tests/resources/tests_collect/test_test3.py b/tests/resources/tests_collect/test_test3.py index bf38cd3..9d46121 100644 --- a/tests/resources/tests_collect/test_test3.py +++ b/tests/resources/tests_collect/test_test3.py @@ -20,12 +20,12 @@ def test_test3_simple_1(): # pragma: no cover - assert 1 + assert True def test_test3_simple_2(): # pragma: no cover - assert 1 + assert True def test_test3_simple_3(): # pragma: no cover - assert 1 + assert True diff --git a/tests/resources/tests_collect/test_test4.py b/tests/resources/tests_collect/test_test4.py index 488ab6c..dc4a745 100644 --- a/tests/resources/tests_collect/test_test4.py +++ b/tests/resources/tests_collect/test_test4.py @@ -23,24 +23,24 @@ @pytest.mark.dep_config("CONFIG_EXAMPLES_HELLO") def test_test4_simple_1(): # pragma: no cover - assert 1 + assert True @pytest.mark.dep_config("CONFIG_XXXXX") def test_test4_simple_2(): # pragma: no cover - assert 1 + assert True @pytest.mark.cmd_check("hello_main") def test_test4_simple_3(): # pragma: no cover - assert 1 + assert True @pytest.mark.cmd_check("xxxx_main") def test_test4_simple_4(): # pragma: no cover - assert 1 + assert True @pytest.mark.extra_opts("xxxx") def test_test4_simple_5(): # pragma: no cover - assert 1 + assert True diff --git a/tests/resources/tests_dirs/test1/test_testdir1.py b/tests/resources/tests_dirs/test1/test_testdir1.py index fc88501..3eab044 100644 --- a/tests/resources/tests_dirs/test1/test_testdir1.py +++ b/tests/resources/tests_dirs/test1/test_testdir1.py @@ -20,8 +20,8 @@ def test_test1_simple_1(): # pragma: no cover - assert 1 + assert True def test_test1_simple_2(): # pragma: no cover - assert 1 + assert True diff --git a/tests/resources/tests_dirs/test2/test_testdir2.py b/tests/resources/tests_dirs/test2/test_testdir2.py index fc88501..3eab044 100644 --- a/tests/resources/tests_dirs/test2/test_testdir2.py +++ b/tests/resources/tests_dirs/test2/test_testdir2.py @@ -20,8 +20,8 @@ def test_test1_simple_1(): # pragma: no cover - assert 1 + assert True def test_test1_simple_2(): # pragma: no cover - assert 1 + assert True diff --git a/tests/resources/tests_dirs/test2/test_testdir3.py b/tests/resources/tests_dirs/test2/test_testdir3.py index a4aae5d..8c0bd36 100644 --- a/tests/resources/tests_dirs/test2/test_testdir3.py +++ b/tests/resources/tests_dirs/test2/test_testdir3.py @@ -20,8 +20,8 @@ def test_test2_simple_1(): # pragma: no cover - assert 1 + assert True def test_test2_simple_2(): # pragma: no cover - assert 1 + assert True diff --git a/tests/resources/tests_dirs/test3/test4/test_testdir4.py b/tests/resources/tests_dirs/test3/test4/test_testdir4.py index fc88501..3eab044 100644 --- a/tests/resources/tests_dirs/test3/test4/test_testdir4.py +++ b/tests/resources/tests_dirs/test3/test4/test_testdir4.py @@ -20,8 +20,8 @@ def test_test1_simple_1(): # pragma: no cover - assert 1 + assert True def test_test1_simple_2(): # pragma: no cover - assert 1 + assert True diff --git a/tests/resources/tests_exitcode/test_success.py b/tests/resources/tests_exitcode/test_success.py index fa91b5b..9bffd2c 100644 --- a/tests/resources/tests_exitcode/test_success.py +++ b/tests/resources/tests_exitcode/test_success.py @@ -20,4 +20,4 @@ def test_test_success(): - assert 1 + assert True diff --git a/tests/resources/tests_smp/test_test1.py b/tests/resources/tests_smp/test_test1.py index 4649c8a..553bcca 100644 --- a/tests/resources/tests_smp/test_test1.py +++ b/tests/resources/tests_smp/test_test1.py @@ -23,18 +23,18 @@ @pytest.mark.extra_opts("--run_in_cores=core0") def test_test_smp_1(core, switch_to_core): # pragma: no cover - assert 1 + assert True @pytest.mark.extra_opts("--run_in_cores=core0,core1") def test_test_smp_2(core, switch_to_core): # pragma: no cover - assert 1 + assert True @pytest.mark.extra_opts("--run_in_cores=core0,core1,core3") def test_test_smp_3(core, switch_to_core): # pragma: no cover - assert 1 + assert True def test_test_smp_4(core, switch_to_core): # pragma: no cover - assert 1 + assert True diff --git a/tests/resources/tests_smp/test_test2.py b/tests/resources/tests_smp/test_test2.py index cbc4d8c..f6201a9 100644 --- a/tests/resources/tests_smp/test_test2.py +++ b/tests/resources/tests_smp/test_test2.py @@ -20,4 +20,4 @@ def test_test_smp_4(core, switch_to_core): # pragma: no cover - assert 1 + assert True