switch to github actions

This commit is contained in:
Johannes Wilm 2022-07-16 23:02:49 +02:00
parent ae950c9b50
commit 8f94d125b3
4 changed files with 46 additions and 49 deletions

44
.github/workflows/test.yml vendored Normal file
View file

@ -0,0 +1,44 @@
name: CI
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
Build:
runs-on: ubuntu-latest
strategy:
matrix:
include:
- python-version: 3.6
DJANGO: 3.2.14
- python-version: 3.7
DJANGO: 3.2.14
- python-version: 3.8
DJANGO: 3.2.14
- python-version: 3.9
DJANGO: 3.2.14
- python-version: '3.10'
DJANGO: 3.2.14
- python-version: 3.8
DJANGO: 4.0.6
- python-version: 3.9
DJANGO: 4.0.6
- python-version: '3.10'
DJANGO: 4.0.6
steps:
- name: 'Set up Python ${{ matrix.python-version }}'
uses: actions/setup-python@v2
with:
python-version: '${{ matrix.python-version }}'
- uses: actions/checkout@v2
- run: pip install coveralls
- run: pip install -e .
- run: pip install -r tests/requirements.txt
- run: 'pip install Django==${DJANGO}'
env:
DJANGO: '${{ matrix.DJANGO }}'
- run: make test
- run: coveralls

View file

@ -1,47 +0,0 @@
language: python
python:
- 2.7
- 3.4
- 3.5
- 3.6
- 3.7
- 3.8
before_install:
- pip install coveralls
install:
- pip install -e .
- pip install -r tests/requirements.txt
- pip install Django==${DJANGO}
script: make test
env:
- DJANGO=1.11.27
- DJANGO=2.0.13
- DJANGO=2.1.15
- DJANGO=2.2.9
- DJANGO=3.0.2
matrix:
exclude:
- python: 3.8
env: DJANGO=1.11.27
- python: 2.7
env: DJANGO=2.0.13
- python: 3.8
env: DJANGO=2.0.13
- python: 2.7
env: DJANGO=2.1.15
- python: 3.4
env: DJANGO=2.1.15
- python: 3.8
env: DJANGO=2.1.15
- python: 2.7
env: DJANGO=2.2.9
- python: 3.4
env: DJANGO=2.2.9
- python: 2.7
env: DJANGO=3.0.2
- python: 3.4
env: DJANGO=3.0.2
- python: 3.5
env: DJANGO=3.0.2
after_success:
- coveralls

View file

@ -5,7 +5,8 @@ export PYTHONPATH=.
test:
flake8 avatar --ignore=E124,E501,E127,E128,E722
coverage run --source=avatar `which django-admin.py` test tests
black --check .
coverage run --source=avatar `which django-admin` test tests
coverage report
publish: clean

View file

@ -1,5 +1,4 @@
import binascii
import datetime
import os
import hashlib
import six