-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
649d47b
commit 0b74b7d
Showing
4 changed files
with
78 additions
and
33 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
[run] | ||
relative_files = True |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,75 @@ | ||
name: CI | ||
|
||
on: | ||
push: | ||
paths-ignore: | ||
- "*.md" | ||
|
||
jobs: | ||
build: | ||
# For compatibility with Python 3.4 | ||
runs-on: ubuntu-18.04 | ||
strategy: | ||
matrix: | ||
python-version: ["3.4", "3.5", "3.6", "3.7", "3.8", "3.9", "3.10"] | ||
defaults: | ||
run: | ||
shell: bash | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Set up Python ${{ matrix.python-version }} | ||
uses: actions/setup-python@v3 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
|
||
- name: Prepare Environment | ||
run: | | ||
python -m pip install --upgrade pip | ||
pip install pytest==3.8.2 | ||
pip install coveralls | ||
pip install -e ".[dev]" | ||
- name: Flake8 | ||
run: | | ||
flake8 quaternions | ||
- name: Tests (3.4) | ||
# Avoid .coveragerc in 3.4 | ||
if: | ||
matrix.python-version == 3.4 | ||
run : | | ||
pytest -v tests/ | ||
- name: Tests | ||
if: | ||
matrix.python-version >= 3.5 | ||
run: | | ||
pytest -v --cov=quaternions --cov-report= tests/ | ||
- name: Publish coverage to Coveralls | ||
# If pushed / is a pull request against main repo | ||
if: | ||
((github.event_name == 'push' && github.repository == 'satellogic/quaternions') || | ||
github.event.pull_request.base.repo.full_name == 'satellogic/quaternions') && matrix.python-version >= 3.5 | ||
uses: AndreMiras/coveralls-python-action@v20201129 | ||
with: | ||
github-token: ${{ secrets.GITHUB_TOKEN }} | ||
flag-name: py${{ matrix.python-version }} | ||
parallel: true | ||
debug: true | ||
|
||
coveralls-finish: | ||
needs: build | ||
# If pushed / is a pull request against main repo | ||
if: | ||
(github.event_name == 'push' && github.repository == 'satellogic/quaternions') || | ||
github.event.pull_request.base.repo.full_name == 'satellogic/quaternions' | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Coveralls finished | ||
uses: AndreMiras/coveralls-python-action@v20201129 | ||
with: | ||
parallel-finished: true | ||
debug: true |
This file was deleted.
Oops, something went wrong.
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