This repository has been archived by the owner on Apr 22, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
57 lines (55 loc) · 1.56 KB
/
ci.yml
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
53
54
55
56
name: CI
on:
schedule:
- cron: "0 0 1 * *" # Run every month
# This way, we can make sure code doesn't break via external dependancies
push:
pull_request:
jobs:
test:
strategy:
matrix:
python-version:
- 3.7
- 3.8
- 3.9
- "3.10"
os: [ubuntu-latest, macos-latest, windows-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Check out repository code
uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Install Poetry
uses: snok/install-poetry@v1
- name: Install dependencies (UNIX)
if: runner.os != 'Windows'
run: |
python3 -m pip install poethepoet
poetry install
poetry install # Second time to install the project
- name: Install dependencies (Windows)
if: runner.os == 'Windows'
run: |
python -m pip install poethepoet
poetry install
poetry install # Second time to install the project
- name: Run test suite
run: poe ci
- name: Upload to CodeCov
uses: codecov/codecov-action@v2
build:
runs-on: ubuntu-latest
steps:
- name: Check out repository code
uses: actions/checkout@v2
- uses: actions/setup-python@v2
with:
python-version: 3
- name: Install Poetry
uses: snok/install-poetry@v1
- name: Build project
run: poetry build