-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Remove tox and use Github Actions (#453)
- Loading branch information
Showing
5 changed files
with
45 additions
and
79 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 |
---|---|---|
@@ -1,56 +1,56 @@ | ||
on: | ||
push: | ||
branches: | ||
- master | ||
pull_request: | ||
name: Run CI checks | ||
|
||
on: pull_request | ||
|
||
permissions: | ||
contents: read | ||
|
||
name: Unit Testing | ||
jobs: | ||
chore: | ||
name: Unit Tests | ||
lint: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
|
||
- uses: actions/setup-python@v4 | ||
|
||
- name: Install dependencies | ||
run: make install | ||
|
||
- name: Run linting and formatting checks | ||
run: make lint | ||
|
||
unit-tests: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
toxenv: [py38, lint, functional] | ||
include: | ||
- toxenv: py38 | ||
python-version: "3.8" | ||
- toxenv: lint | ||
python-version: "3.X" | ||
- toxenv: functional | ||
python-version: "3.11" | ||
|
||
python-version: ["3.9", "3.10", "3.11"] | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/checkout@v3 | ||
|
||
- uses: actions/setup-python@v2 | ||
- name: Set up Python ${{ matrix.python-version }} | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
cache: pip | ||
cache-dependency-path: pyproject.toml | ||
|
||
- name: Install virtualenv | ||
run: | | ||
pip install virtualenv | ||
virtualenv --python=python3 .venv | ||
- name: Run unit tests | ||
run: make test | ||
|
||
- name: Print environment | ||
run: | | ||
source .venv/bin/activate | ||
python --version | ||
pip --version | ||
functional-tests: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
|
||
- name: Install dependencies | ||
run: | | ||
source .venv/bin/activate | ||
pip install tox | ||
- uses: actions/setup-python@v4 | ||
with: | ||
python-version: "3.11" | ||
|
||
- name: Run Kinto | ||
if: matrix.toxenv == 'functional' | ||
run: | | ||
source .venv/bin/activate | ||
make run-kinto & sleep 5 | ||
- name: Install dependencies | ||
run: make install | ||
|
||
- name: Tox | ||
run: | | ||
source .venv/bin/activate | ||
tox -e ${{ matrix.toxenv }} | ||
- name: Run kinto | ||
run: make run-kinto & sleep 5 | ||
|
||
- name: Run functional tests | ||
run: make functional |
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 |
---|---|---|
@@ -1,5 +1,4 @@ | ||
.cache | ||
.tox | ||
.coverage | ||
.pytest_cache | ||
.ruff_cache | ||
|
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
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 |
---|---|---|
|
@@ -38,7 +38,6 @@ dev = [ | |
"pytest", | ||
"pytest-cache", | ||
"pytest-cov", | ||
"tox", | ||
"webtest", | ||
] | ||
|
||
|