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+ name : Tests
2+
3+ on :
4+ push :
5+ branches : [main]
6+ pull_request :
7+ branches : [main]
8+
9+ jobs :
10+ test :
11+ runs-on : ubuntu-latest
12+ strategy :
13+ matrix :
14+ python-version : ["3.10", "3.11", "3.12", "3.13"]
15+
16+ steps :
17+ - uses : actions/checkout@v4
18+
19+ - name : Set up Python ${{ matrix.python-version }}
20+ uses : actions/setup-python@v5
21+ with :
22+ python-version : ${{ matrix.python-version }}
23+
24+ - name : Install dependencies
25+ run : pip install -e ".[dev]"
26+
27+ - name : Lint
28+ run : ruff check src/ tests/
29+
30+ - name : Run tests
31+ run : pytest tests/ -v --tb=short
32+
33+ coverage :
34+ runs-on : ubuntu-latest
35+ needs : test
36+ steps :
37+ - uses : actions/checkout@v4
38+
39+ - name : Set up Python
40+ uses : actions/setup-python@v5
41+ with :
42+ python-version : " 3.12"
43+
44+ - name : Install dependencies
45+ run : pip install -e ".[dev]" pytest-cov
46+
47+ - name : Run tests with coverage
48+ run : pytest tests/ --cov=plivo_agent --cov-report=xml
49+
50+ - name : Upload coverage to Codecov
51+ uses : codecov/codecov-action@v4
52+ with :
53+ file : coverage.xml
54+ fail_ci_if_error : false
55+ env :
56+ CODECOV_TOKEN : ${{ secrets.CODECOV_TOKEN }}
You can’t perform that action at this time.
0 commit comments