-
Notifications
You must be signed in to change notification settings - Fork 18
52 lines (43 loc) · 1.14 KB
/
run-python-tests.yaml
File metadata and controls
52 lines (43 loc) · 1.14 KB
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
48
49
50
51
52
name: Run tests
on:
workflow_dispatch:
push:
branches-ignore: [gh-pages, "dependabot/**"]
pull_request:
branches-ignore: [gh-pages]
jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: read
checks: write
pull-requests: write
steps:
- uses: actions/checkout@v6
- name: Install uv
uses: astral-sh/setup-uv@v7
with:
enable-cache: true
python-version: "3.13"
- name: Install dependencies
run: uv sync --frozen
- name: Check styling
run: |
uv run ruff format --check
uv run ruff check
- name: Test with pytest
env:
HDX_KEY_TEST: ${{ secrets.HDX_BOT_SCRAPERS_API_TOKEN }}
GSHEET_AUTH: ${{ secrets.HDX_PIPELINE_GSHEET_AUTH }}
run: uv run pytest
- name: Publish Unit Test Results
uses: EnricoMi/publish-unit-test-result-action@v2
if: always()
with:
files: test-results.xml
- name: Publish in Coveralls
uses: coverallsapp/github-action@v2
if: always()
with:
flag-name: tests
format: lcov