Skip to content

Commit 6a13b1a

Browse files
committed
Add CI build which checks sdist testing
1 parent 22c1a72 commit 6a13b1a

File tree

1 file changed

+22
-0
lines changed

1 file changed

+22
-0
lines changed

.github/workflows/build.yaml

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,28 @@ jobs:
3636

3737
- run: python -m tox run -e "${{ matrix.toxenv }}"
3838

39+
# run tests after building an sdist and unpacking it
40+
test-sdist:
41+
runs-on: ubuntu-latest
42+
steps:
43+
- uses: actions/checkout@v3
44+
- uses: actions/setup-python@v4
45+
with:
46+
python-version: "3.x"
47+
- name: install requirements
48+
run: python -m pip install build tox
49+
- name: build and unpack sdist
50+
run: |
51+
python -m build --sdist
52+
version="$(grep '^version' setup.cfg | cut -d '=' -f2 | tr -d ' ')"
53+
cd dist
54+
tar -xzf "check-jsonschema-${version}.tar.gz"
55+
- name: test
56+
run: |
57+
version="$(grep '^version' setup.cfg | cut -d '=' -f2 | tr -d ' ')"
58+
cd "dist/check-jsonschema-${version}"
59+
python -m tox run -m ci
60+
3961
ci-test-matrix:
4062
strategy:
4163
matrix:

0 commit comments

Comments
 (0)