Skip to content

Commit fc9728a

Browse files
ci: enforce 80% coverage gate and improve repo hygiene
- Add --cov-fail-under=80 gate to pytest addopts - Enable pip cache and job concurrency (cancel in-progress) in CI - Add dependabot for pip and GitHub Actions - Switch to SPDX license expression - Wrap Streamlit app entry in main() guarded by __name__ to make it importable - Add app-entry smoke test and merge test_load_data into test_data (dedup) - Add .gitattributes for LF normalization and binary png markers
1 parent eb7fbdf commit fc9728a

8 files changed

Lines changed: 796 additions & 744 deletions

File tree

.gitattributes

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# Normalizar saltos de línea a LF en texto, mantener binarios intactos
2+
* text=auto
3+
4+
*.png binary
5+
*.jpg binary
6+
*.csv text eol=lf

.github/dependabot.yml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
version: 2
2+
updates:
3+
- package-ecosystem: "pip"
4+
directory: "/"
5+
schedule:
6+
interval: "weekly"
7+
open-pull-requests-limit: 5
8+
9+
- package-ecosystem: "github-actions"
10+
directory: "/"
11+
schedule:
12+
interval: "weekly"
13+
open-pull-requests-limit: 5

.github/workflows/ci.yml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,10 @@ on:
66
pull_request:
77
branches: [ main ]
88

9+
concurrency:
10+
group: ci-${{ github.workflow }}-${{ github.ref }}
11+
cancel-in-progress: true
12+
913
jobs:
1014
lint:
1115
runs-on: ubuntu-latest
@@ -16,6 +20,7 @@ jobs:
1620
uses: actions/setup-python@v5
1721
with:
1822
python-version: "3.12"
23+
cache: pip
1924

2025
- name: Install dependencies
2126
run: |
@@ -41,13 +46,14 @@ jobs:
4146
uses: actions/setup-python@v5
4247
with:
4348
python-version: ${{ matrix.python-version }}
49+
cache: pip
4450

4551
- name: Install dependencies
4652
run: |
4753
python -m pip install --upgrade pip
4854
pip install -e ".[dev]"
4955
50-
- name: Run tests
56+
- name: Run tests (coverage gate >=80%)
5157
run: pytest
5258

5359
- name: Upload coverage report

0 commit comments

Comments
 (0)