From a42a35269a5df556f940e0ac1f16984adefdb39c Mon Sep 17 00:00:00 2001 From: Andrew Murray Date: Mon, 14 Jun 2021 22:58:40 +1000 Subject: [PATCH] Reverse test order for two jobs --- .ci/test.sh | 2 +- .github/workflows/test.yml | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/.ci/test.sh b/.ci/test.sh index 9d2c123da..8ff7c5f64 100755 --- a/.ci/test.sh +++ b/.ci/test.sh @@ -4,4 +4,4 @@ set -e python3 -c "from PIL import Image" -python3 -bb -m pytest -v -x -W always --cov PIL --cov Tests --cov-report term Tests +python3 -bb -m pytest -v -x -W always --cov PIL --cov Tests --cov-report term Tests $REVERSE diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index f2953072a..042e6d83e 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -24,6 +24,7 @@ jobs: include: - python-version: "3.6" PYTHONOPTIMIZE: 1 + REVERSE: "--reverse" - python-version: "3.7" PYTHONOPTIMIZE: 2 # Include new variables for Codecov @@ -80,6 +81,9 @@ jobs: - name: Test run: | + if [ $REVERSE ]; then + python3 -m pip install pytest-reverse + fi if [ "${{ matrix.os }}" = "ubuntu-latest" ]; then xvfb-run -s '-screen 0 1024x768x24' .ci/test.sh else @@ -87,6 +91,7 @@ jobs: fi env: PYTHONOPTIMIZE: ${{ matrix.PYTHONOPTIMIZE }} + REVERSE: ${{ matrix.REVERSE }} - name: Prepare to upload errors if: failure()