File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ # This workflow will install all necessary Python dependencies and run the unit tests
2+
3+ name : Unit tests
4+
5+ on :
6+ push :
7+ branches : [ main ]
8+ pull_request :
9+ branches : [ main ]
10+
11+ jobs :
12+ build :
13+
14+ runs-on : ubuntu-latest
15+ strategy :
16+ matrix :
17+ python-version : [3.8]
18+
19+ steps :
20+ - uses : actions/checkout@v2
21+ - name : Set up Python ${{ matrix.python-version }}
22+ uses : actions/setup-python@v2
23+ with :
24+ python-version : ${{ matrix.python-version }}
25+
26+ - name : Install dependencies
27+ run : |
28+ python -m pip install --upgrade pip
29+ pip install pytest coverage codecov
30+
31+ - name : Test with pytest
32+ run : |
33+ # run tests with coverage and pytest
34+ coverage run -m pytest
35+ coverage report -m --omit "*/site-packages/*.py"
36+ coverage html --omit "*/site-packages/*.py"
37+ # codecov -t ${{ secrets.CODECOV_TOKEN }}
You can’t perform that action at this time.
0 commit comments