add tests and CI workflow

This commit is contained in:
Bachynin Ivan 2019-11-09 20:45:55 +02:00
parent a7aabeaf49
commit ae0da89217
4 changed files with 52086 additions and 0 deletions

25
.github/workflows/test.yml vendored Normal file
View File

@ -0,0 +1,25 @@
name: test
on: [push]
jobs:
test:
runs-on: ${{ matrix.os }}
strategy:
max-parallel: 4
matrix:
python-version: [2.7, 3.7]
os: [ubuntu-latest, windows-latest]
steps:
- uses: actions/checkout@v1
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v1
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: Test
run: pytest -v -n auto --cov=my_first_calculator --cov-fail-under 69 tests.py

8
.gitignore vendored
View File

@ -45,3 +45,11 @@ $RECYCLE.BIN/
Network Trash Folder
Temporary Items
.apdisk
# Coverage
.coverage
htmlcov
# Environment
.venv
.env

3
requirements.txt Normal file
View File

@ -0,0 +1,3 @@
pytest
pytest-cov
pytest-xdist

52050
tests.py Normal file

File diff suppressed because it is too large Load Diff