Skip to content

Commit e8067c9

Browse files
committed
add test workflow
1 parent fa86bc7 commit e8067c9

2 files changed

Lines changed: 31 additions & 2 deletions

File tree

.github/workflows/ci.yml

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
branches: [main]
6+
pull_request:
7+
8+
jobs:
9+
test:
10+
runs-on: ubuntu-latest
11+
12+
steps:
13+
- uses: actions/checkout@v4
14+
15+
- uses: astral-sh/setup-uv@v5
16+
with:
17+
python-version: "3.11"
18+
19+
- name: Install dependencies
20+
run: uv sync --extra dev
21+
22+
- name: Run tests
23+
run: uv run pytest tests/ -m "not slow" --cov=bordax --cov-report=xml
24+
25+
- name: Upload coverage to Codecov
26+
uses: codecov/codecov-action@v4
27+
with:
28+
files: ./coverage.xml
29+
token: ${{ secrets.CODECOV_TOKEN }}

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@
77
[![Python 3.11+](https://img.shields.io/badge/python-3.11+-blue.svg)](https://www.python.org/downloads/)
88
[![JAX](https://img.shields.io/badge/JAX-0.8.0+-orange.svg)](https://github.com/google/jax)
99
[![License: MIT](https://img.shields.io/badge/License-MIT-green.svg)](https://opensource.org/licenses/MIT)
10-
[![Tests](https://img.shields.io/badge/tests-48%20passed-brightgreen.svg)](#testing)
11-
[![Coverage](https://img.shields.io/badge/coverage-77%25-yellowgreen.svg)](#testing)
10+
[![CI](https://github.com/SynthesisLab/bordax/actions/workflows/ci.yml/badge.svg)](https://github.com/SynthesisLab/bordax/actions/workflows/ci.yml)
11+
[![Coverage](https://codecov.io/gh/SynthesisLab/bordax/branch/main/graph/badge.svg)](https://codecov.io/gh/SynthesisLab/bordax)
1212
[![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)
1313

1414
</div>

0 commit comments

Comments
 (0)