Skip to content

Commit

Permalink
Enable github actions to test dependency (#1367)
Browse files Browse the repository at this point in the history
Signed-off-by: yangxuan <[email protected]>
  • Loading branch information
XuanYang-cn authored Apr 21, 2023
1 parent db86668 commit 80c0aef
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 17 deletions.
35 changes: 18 additions & 17 deletions .github/workflows/pull_request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,25 +11,26 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: [3.8]
python-version: [3.8, 3.11]

steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Checkout code
uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}

- name: Fetch tags
run: |
git fetch --prune --unshallow --tags
- name: Fetch tags
run: |
git fetch --prune --unshallow --tags
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install pytest
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python setup.py install
pip install -r test_requirements.txt
- name: Test with pytest
run: |
make unittest
- name: Test with pytest
run: |
make unittest
6 changes: 6 additions & 0 deletions test_requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
pytest>=5.3.4
pytest-cov==2.8.1
pytest-timeout==1.3.4
pylint==2.13.9
grpcio-testing
sklearn==0.0

0 comments on commit 80c0aef

Please sign in to comment.