Skip to content

Commit

Permalink
Backport PR #52239 on branch 2.0.x (CI: Try running single_cpu/not si…
Browse files Browse the repository at this point in the history
…ngle_cpu tests together) (#52292)

Backport PR #52239: CI: Try running single_cpu/not single_cpu tests together

Co-authored-by: Thomas Li <47963215+lithomas1@users.noreply.github.com>
  • Loading branch information
meeseeksmachine and lithomas1 committed Mar 30, 2023
1 parent f7917ca commit 6c1756c
Showing 1 changed file with 17 additions and 3 deletions.
20 changes: 17 additions & 3 deletions .github/workflows/ubuntu.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,8 @@ jobs:
strategy:
matrix:
env_file: [actions-38.yaml, actions-39.yaml, actions-310.yaml, actions-311.yaml]
pattern: ["not single_cpu", "single_cpu"]
# Prevent the include jobs from overriding other jobs
pattern: [""]
pyarrow_version: ["8", "9", "10"]
include:
- name: "Downstream Compat"
Expand Down Expand Up @@ -99,7 +100,7 @@ jobs:
PANDAS_COPY_ON_WRITE: ${{ matrix.pandas_copy_on_write || '0' }}
PANDAS_CI: ${{ matrix.pandas_ci || '1' }}
TEST_ARGS: ${{ matrix.test_args || '' }}
PYTEST_WORKERS: ${{ contains(matrix.pattern, 'not single_cpu') && 'auto' || '1' }}
PYTEST_WORKERS: 'auto'
PYTEST_TARGET: ${{ matrix.pytest_target || 'pandas' }}
IS_PYPY: ${{ contains(matrix.env_file, 'pypy') }}
# TODO: re-enable coverage on pypy, its slow
Expand Down Expand Up @@ -168,9 +169,22 @@ jobs:
pyarrow-version: ${{ matrix.pyarrow_version }}

- name: Build Pandas
id: build
uses: ./.github/actions/build_pandas

- name: Test
- name: Test (not single_cpu)
uses: ./.github/actions/run-tests
# TODO: Don't continue on error for PyPy
continue-on-error: ${{ env.IS_PYPY == 'true' }}
env:
# Set pattern to not single_cpu if not already set
PATTERN: ${{ env.PATTERN == '' && 'not single_cpu' || matrix.pattern }}

- name: Test (single_cpu)
uses: ./.github/actions/run-tests
# TODO: Don't continue on error for PyPy
continue-on-error: ${{ env.IS_PYPY == 'true' }}
env:
PATTERN: 'single_cpu'
PYTEST_WORKERS: 1
if: ${{ matrix.pattern == '' && (always() && steps.build.outcome == 'success')}}

0 comments on commit 6c1756c

Please sign in to comment.