From 86cdf99f2ac7c46153ca2b2fccb932a0e0e14993 Mon Sep 17 00:00:00 2001 From: Ewout ter Hoeven Date: Sat, 10 Aug 2024 22:16:08 +0200 Subject: [PATCH] CI: Let pytest treat warnings as errors Uses the -Werror option of pytest to treat warnings as errors. See https://docs.python.org/3/using/cmdline.html#cmdoption-W --- .github/workflows/build_lint.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build_lint.yml b/.github/workflows/build_lint.yml index 112de27e..0da5147b 100644 --- a/.github/workflows/build_lint.yml +++ b/.github/workflows/build_lint.yml @@ -35,7 +35,7 @@ jobs: # - name: Install dependencies # run: pip install mesa pytest # - name: Test with pytest - # run: pytest test_examples.py + # run: pytest -rA -Werror test_examples.py build-pre: runs-on: ubuntu-latest @@ -50,7 +50,7 @@ jobs: pip install mesa --pre pip install pytest - name: Test with pytest - run: pytest -rA test_examples.py + run: pytest -rA -Werror test_examples.py build-main: runs-on: ubuntu-latest @@ -65,4 +65,4 @@ jobs: pip install pytest pip install -U git+https://github.com/projectmesa/mesa@main#egg=mesa - name: Test with pytest - run: pytest -rA test_examples.py + run: pytest -rA -Werror test_examples.py