v7.0.0 #231
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Run tests | |
on: | |
push: | |
branches: | |
- master | |
pull_request: | |
jobs: | |
# Tests that are platform-agnostic. | |
universal: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Set up Python 3.9 | |
uses: actions/setup-python@v4 | |
with: | |
python-version: 3.11 | |
- uses: actions/checkout@v3 | |
- name: Installing platform dependencies | |
run: > | |
sudo apt-get install -y | |
build-essential | |
clang-15 | |
- name: Installing python dependencies | |
env: | |
BUILD_WITH_CYTHON: 1 | |
BUILD_FOR_DEBUG: 1 | |
run: | | |
python -m pip install --upgrade pip wheel | |
pip install cython | |
pip install -e '.[test]' | |
rm simdjson/csimdjson.cpp | |
python setup.py develop | |
- name: Running tests with pytest | |
run: | | |
coverage run -m pytest | |
- name: Generating coverage report | |
run: | | |
coverage report -m | |
- name: Checking flake8 | |
run: | | |
flake8 | |
build: | |
runs-on: ${{ matrix.os }} | |
strategy: | |
fail-fast: true | |
matrix: | |
os: [ubuntu-latest, macos-latest, windows-latest] | |
python-version: [3.8, 3.9, "3.10", "3.11"] | |
steps: | |
# Python needs to be setup before checkout to prevent files from being | |
# left in the source tree. See setup-python/issues/106. | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v4 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- uses: actions/checkout@v3 | |
- name: Installing platform dependencies | |
if: matrix.os == 'ubuntu-latest' | |
run: > | |
sudo apt-get install -y | |
build-essential | |
clang-15 | |
- name: Installing python dependencies | |
env: | |
BUILD_WITH_CYTHON: 1 | |
run: | | |
python -m pip install --upgrade pip wheel | |
pip install cython | |
pip install -e '.[test]' | |
rm simdjson/csimdjson.cpp | |
python setup.py develop | |
- name: Running tests with pytest | |
run: | | |
pytest |