Skip to content

Commit 92451da

Browse files
committed
add GH actions that run pytest and markdown-link-check in CI
add CI tests and pre-commit.ci status badge to readme
1 parent e54a8c6 commit 92451da

File tree

3 files changed

+52
-0
lines changed

3 files changed

+52
-0
lines changed

.github/workflows/link-check.yml

+17
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
name: Link check
2+
3+
on:
4+
push:
5+
branches: [main]
6+
pull_request:
7+
branches: [main]
8+
9+
jobs:
10+
markdown-link-check:
11+
runs-on: ubuntu-latest
12+
steps:
13+
- name: Check out repo
14+
uses: actions/checkout@v3
15+
16+
- name: Run markdown link check
17+
uses: gaurav-nelson/github-action-markdown-link-check@v1

.github/workflows/test.yml

+32
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: Tests
2+
3+
on:
4+
push:
5+
branches: [main]
6+
pull_request:
7+
branches: [main]
8+
9+
jobs:
10+
tests:
11+
strategy:
12+
matrix:
13+
os: [ubuntu-latest, windows-latest]
14+
runs-on: ${{ matrix.os }}
15+
16+
steps:
17+
- name: Check out repo
18+
uses: actions/checkout@v3
19+
20+
- name: Set up python
21+
uses: actions/setup-python@v4
22+
with:
23+
python-version: 3.8
24+
cache: pip
25+
cache-dependency-path: setup.py
26+
27+
- name: Install dependencies
28+
run: pip install -e .[test]
29+
30+
- name: Run tests
31+
id: tests
32+
run: pytest --durations 0 --cov mb_discovery

readme.md

+3
Original file line numberDiff line numberDiff line change
@@ -1 +1,4 @@
11
# Matbench Discovery
2+
3+
[![Link check](https://github.com/janosh/matbench-discovery/actions/workflows/test.yml/badge.svg)](https://github.com/janosh/matbench-discovery/actions/workflows/test.yml)
4+
[![pre-commit.ci status](https://results.pre-commit.ci/badge/github/janosh/matbench-discovery/main.svg?badge_token=Qza33izjRxSbegTqeSyDvA)](https://results.pre-commit.ci/latest/github/janosh/matbench-discovery/main?badge_token=Qza33izjRxSbegTqeSyDvA)

0 commit comments

Comments
 (0)