-
Notifications
You must be signed in to change notification settings - Fork 0
40 lines (38 loc) · 1011 Bytes
/
test.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
name: Build & Tests
on:
push:
branches: '**'
pull_request:
branches: '**'
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up Python 3.8
uses: actions/setup-python@v2
with:
python-version: 3.8
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt;
- name: Start test environment
run: docker-compose -f test_environment.yml up -d
- name: Test with unittest and coverage-report
env:
TOKEN: ${{ secrets.IBMQ_TOKEN }}
run: |
coverage run --branch --include 'app/*' -m unittest discover
coverage report
coverage xml
- name: Upload Coverage to Codecov
timeout-minutes: 1
uses: codecov/codecov-action@v2
with:
fail_ci_if_error: false
verbose: true
files: ./coverage.xml
flags: unittests
- name: Check code style
run: black --check .