remove travis-ci and add github actions workflows

This commit is contained in:
Gonçalo Valério 2021-01-20 17:11:36 +00:00
parent 49ccaeb5cb
commit bf7b9d2af5
4 changed files with 51 additions and 36 deletions

22
.github/workflows/format-check.yml vendored Normal file
View File

@ -0,0 +1,22 @@
name: Format check
on: ["push", "pull_request"]
jobs:
format-check:
name: Check Codebase format
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Set up Python 3.9
uses: actions/setup-python@v2
with:
python-version: 3.9
- name: Run Black
run: |
black --version
black . --check

28
.github/workflows/run-test-suite.yml vendored Normal file
View File

@ -0,0 +1,28 @@
name: Run Test Suite
on: ["push", "pull_request"]
jobs:
name: Run Test Suite
runs-on: ubuntu-latest
strategy:
matrix:
python_version: [3.6, 3.7, 3.8]
django_version: ["django-22", "django-30"]
steps:
- 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: Run Tests
run: tox -e py${{ matrix.python_version }}-${{ matrix.django_version }}
- name: Coveralls
uses: coverallsapp/github-action@master
with:
github-token: ${{ secrets.GITHUB_TOKEN }}

View File

@ -1,36 +0,0 @@
# Config file for automatic testing at travis-ci.org
stages:
- format
- test
language: python
jobs:
include:
- stage: format
name: "Black format check"
python: "3.7"
install: pip install black
script:
- black --version
- black . --check
after_success: ""
python:
- "3.6"
- "3.7"
- "3.8"
env:
- DJANGO_VERSION=django-22
- DJANGO_VERSION=django-30
# command to install dependencies, e.g. pip install -r requirements.txt --use-mirrors
install: pip install -r requirements_test.txt
# command to run tests using coverage, e.g. python setup.py test
script: tox -e $(echo py$TRAVIS_PYTHON_VERSION-$DJANGO_VERSION | tr -d .)
after_success:
- coveralls

View File

@ -9,6 +9,7 @@ Development
* Challenges are now stored on the database. No longer expire when a new one is
generated.
* Added initial support for DRF, TokenAuthentication only.
* Move CI from Travis-ci to Github Actions
0.1.0 (2020-03-31)