-
Notifications
You must be signed in to change notification settings - Fork 2
39 lines (36 loc) · 1.03 KB
/
test.yaml
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
---
name: test
on:
push:
workflow_dispatch:
# Tests must always run! How can I reuse this?
jobs:
test:
runs-on: ubuntu-latest
steps:
- name: Checkout Repository.
uses: actions/checkout@v3
- name: Setup Python.
uses: actions/setup-python@v4
with:
python-version: '3.10'
# Eventually this step should be replaced with pip install .[test] instead.
# BUG: pip install .[test] does not install pytest. See pipeline number 3.
- name: Install Dependencies.
run: |-
python3 -m venv .venv
source .venv/bin/activate
python3 -m pip install poetry
python3 -m poetry install --with test
- name: Test
run: |-
source .venv/bin/activate
# which python3
# python3 -m pip list
python3 -m pytest
- name: Verify Build.
run: |-
source .venv/bin/activate
python3 -m poetry install --with ci
python3 -m build
python3 -m twine check dist/*