Repository navigation
47 lines (44 loc) · 1.54 KB
/
Copy pathci.yml
File metadata and controls
47 lines (44 loc) · 1.54 KB
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
name: Python package
on:
pull_request:
push:
branches: [main]
permissions:
contents: read
jobs:
test:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
python-version: ["3.10", "3.12"]
steps:
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- uses: actions/setup-python@5fda3b95a4ea91299a34e894583c3862153e4b97 # v7.0.0
with:
python-version: ${{ matrix.python-version }}
cache: pip
cache-dependency-path: pyproject.toml
- name: Install package and build tools
run: python -m pip install . build pytest twine
- name: Source tests
run: python -m pytest -q python-client/tests
- name: Build wheel and source distribution
run: python -m build
- name: Check metadata and archive contents
run: |
python -m twine check --strict dist/*
python tools/check_python_dist.py dist/*
python -m pip install --force-reinstall --no-deps dist/*.whl
- name: Smoke-test installed package outside checkout
working-directory: ${{ runner.temp }}
env:
SIDEPIT_TESTNET: "true"
SIDEPIT_DEPOSIT_ADDRESS: bc1ql3e9pgs3mmwuwrh95fecme0s0qtn2880lsvsd5
SIDEPIT_KEYS_DIR: ${{ runner.temp }}/sidepit-empty-keys
SIDEPIT_STATE_DB: ${{ runner.temp }}/sidepit-empty-state.db
SIDEPIT_HOST: localhost
run: |
sidepit --help
sidepit list
python "$GITHUB_WORKSPACE/tools/smoke_installed_sidepit.py"