Skip to content

Commit

Permalink
add capability to target branch for unit test in cpu on tox (#58)
Browse files Browse the repository at this point in the history
* add capability to target branch for unit test in cpu on tox

* fix cpu ci yml file name of next stage

* fix tox command in cpu ci
  • Loading branch information
jperez999 committed Nov 23, 2022
1 parent 858f0dd commit 98e757a
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 3 deletions.
9 changes: 8 additions & 1 deletion .github/workflows/cpu-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,14 @@ jobs:
tox -re lint
- name: Run unittests
run: |
tox -re test-cpu
ref_type=${{ github.ref_type }}
branch=main
if [[ $ref_type == "tag"* ]]
then
raw=$(git branch -r --contains ${{ github.ref_name }})
branch=${raw/origin\/}
fi
tox -e test-cpu -- $branch
- name: Generate package for pypi
run: |
python setup.py sdist
Expand Down
5 changes: 3 additions & 2 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,9 @@ deps =
-rrequirements/base.txt
-rrequirements/dev.txt
commands =
python -m pip install --upgrade git+https://github.com/NVIDIA-Merlin/core.git
python -m pip install --upgrade git+https://github.com/NVIDIA-Merlin/nvtabular.git
echo {posargs:main}
python -m pip install --upgrade git+https://github.com/NVIDIA-Merlin/core.git@{posargs:main}
python -m pip install --upgrade git+https://github.com/NVIDIA-Merlin/nvtabular.git@{posargs:main}
python -m pip install -e .[all]
python -m pip install fsspec==2022.5.0
python -m pytest --cov-report term --cov=merlin -rxs tests/unit
Expand Down

0 comments on commit 98e757a

Please # to comment.