Skip to content

Commit

Permalink
Merge pull request #37 from mgedmin/fix-pypy-on-gha
Browse files Browse the repository at this point in the history
Fix pypy on GHA
  • Loading branch information
mgedmin committed Dec 11, 2022
2 parents fa066c3 + 96d0d42 commit c9c6e2a
Showing 1 changed file with 10 additions and 9 deletions.
19 changes: 10 additions & 9 deletions .github/workflows/build.yml
Expand Up @@ -26,22 +26,23 @@ jobs:
- "3.9"
- "3.10"
- "3.11"
- "pypy-3.7"
- "pypy2.7"
- "pypy3.7"

steps:
- name: Install OS dependencies
run: sudo apt install -y libxml2-dev libxslt1-dev

- name: Git clone
uses: actions/checkout@v2
uses: actions/checkout@v3

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
uses: actions/setup-python@v4
with:
python-version: "${{ matrix.python-version }}"

- name: Pip cache
uses: actions/cache@v2
uses: actions/cache@v3
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ matrix.python-version }}-${{ hashFiles('tox.ini', 'setup.py') }}
Expand All @@ -60,11 +61,11 @@ jobs:
run: coverage run -m zope.testrunner --test-path=src --tests-pattern="^f?tests$"

- name: Check test coverage
run: coverage report -m --fail-under=${{ matrix.python-version == 'pypy2' && 98 || 100 }}
run: coverage report -m --fail-under=${{ matrix.python-version == 'pypy2.7' && 98 || 100 }}

- name: Report to coveralls
run: coveralls
if: "matrix.python-version != '2.7' && matrix.python-version != 'pypy2'"
if: "matrix.python-version != '2.7' && matrix.python-version != 'pypy2.7'"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
COVERALLS_SERVICE_NAME: github
Expand All @@ -83,15 +84,15 @@ jobs:

steps:
- name: Git clone
uses: actions/checkout@v2
uses: actions/checkout@v3

- name: Set up Python ${{ env.default_python || '3.9' }}
uses: actions/setup-python@v2
uses: actions/setup-python@v4
with:
python-version: "${{ env.default_python || '3.9' }}"

- name: Pip cache
uses: actions/cache@v2
uses: actions/cache@v3
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ matrix.toxenv }}-${{ hashFiles('tox.ini') }}
Expand Down

0 comments on commit c9c6e2a

Please sign in to comment.