-
Notifications
You must be signed in to change notification settings - Fork 6
47 lines (44 loc) · 1.26 KB
/
test.yaml
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
41
42
43
44
45
46
47
# This is a basic workflow to help you get started with Actions
name: Testing
# Controls when the workflow will run
on:
# Triggers the workflow on push or pull request events but only for the main branch
push:
branches:
- main
- auto_test
- dev
- dev_1.0_grammar
pull_request:
branches:
- main
- auto_test
- dev
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
# This workflow contains a single job called "test"
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v3
with:
python-version: 3.9
- name: Install poetry
uses: abatilo/actions-poetry@v2.0.0
with:
poetry-version: 1.1.12
- name: Install dependencies
run: |
poetry update --no-dev
poetry run python -m pip install pytest-cov
- name: Run tests
run: |
cd tests
poetry run python -m pytest --cov=../glyles/ --cov-report=xml -m "not todo"
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v3
with:
token: ${{ secrets.CODECOV_TOKEN }}
fail_ci_if_error: false
files: coverage.xml