Skip to content

Commit

Permalink
CI GPU
Browse files Browse the repository at this point in the history
  • Loading branch information
luweizheng committed Aug 19, 2024
1 parent 3e995ba commit a94f7d9
Showing 1 changed file with 13 additions and 9 deletions.
22 changes: 13 additions & 9 deletions .github/workflows/python.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -141,18 +141,22 @@ jobs:
working-directory: ./python

- name: Test with pytest
env:
MODULE: ${{ matrix.module }}
if: ${{ matrix.module != 'gpu' }}
run: |
if [[ "$MODULE" == "xoscar" ]]; then
pytest --timeout=1500 \
-W ignore::PendingDeprecationWarning \
--cov-config=setup.cfg --cov-report=xml --cov=xoscar xoscar --capture=no
else
${{ env.SELF_HOST_PYTHON }} -m pytest -m cuda --cov-config=setup.cfg --cov-report=xml --cov=xoscar --capture=no
fi
pytest --timeout=1500 \
-W ignore::PendingDeprecationWarning \
--cov-config=setup.cfg --cov-report=xml \
--cov=xoscar xoscar --capture=no
working-directory: ./python

- name: Test with pytest GPU
if: ${{ matrix.module == 'gpu' }}
run: |
${{ env.SELF_HOST_PYTHON }} -m pytest -m cuda \
--cov-config=setup.cfg --cov-report=xml \
--cov=xoscar --capture=no
working-directory: ./python

- name: Report coverage data
uses: codecov/codecov-action@v4
with:
Expand Down

0 comments on commit a94f7d9

Please sign in to comment.