Skip to content

Commit f68ac3e

Browse files
committed
Merge PR #111 into unstable/v1
This patch adds a simple GHA-based smoke test that uses devpi to verify the main success path of the action.
2 parents 5d1679f + 7ef975b commit f68ac3e

File tree

1 file changed

+45
-0
lines changed

1 file changed

+45
-0
lines changed

.github/workflows/test-upload.yml

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
name: Test Upload
2+
3+
on:
4+
pull_request:
5+
push:
6+
7+
jobs:
8+
test:
9+
runs-on: ubuntu-latest
10+
services:
11+
devpi:
12+
image: muccg/devpi
13+
env:
14+
DEVPI_PASSWORD: abcd1234
15+
ports:
16+
- 3141
17+
steps:
18+
- run: python3 -m pip install --upgrade pip build twine
19+
- run: mkdir -p src/test_package
20+
- run: echo '__version__ = "0.1"' > src/test_package/__init__.py
21+
- run: echo "# Test Package" > README.md
22+
- run: echo "$CONTENTS" > pyproject.toml
23+
env:
24+
CONTENTS: |
25+
[build-system]
26+
requires = ["setuptools>=61", "wheel"]
27+
build-backend = "setuptools.build_meta"
28+
[project]
29+
name = "test-package"
30+
version = "0.1"
31+
readme = "README.md"
32+
- run: python3 -m build
33+
- run: twine register dist/*.tar.gz
34+
env:
35+
TWINE_USERNAME: root
36+
TWINE_PASSWORD: abcd1234
37+
TWINE_REPOSITORY_URL: http://localhost:${{ job.services.devpi.ports['3141'] }}/root/public/
38+
- uses: actions/checkout@v3
39+
with:
40+
path: test
41+
- uses: ./test
42+
with:
43+
user: root
44+
password: abcd1234
45+
repository_url: http://devpi:3141/root/public/

0 commit comments

Comments
 (0)