summaryrefslogtreecommitdiff
path: root/.github/workflows/python-tests.yml
diff options
context:
space:
mode:
Diffstat (limited to '.github/workflows/python-tests.yml')
-rw-r--r--.github/workflows/python-tests.yml46
1 files changed, 42 insertions, 4 deletions
diff --git a/.github/workflows/python-tests.yml b/.github/workflows/python-tests.yml
index 4822766..b34d0a6 100644
--- a/.github/workflows/python-tests.yml
+++ b/.github/workflows/python-tests.yml
@@ -6,7 +6,7 @@ on:
branches: [master]
jobs:
- build:
+ test:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
@@ -29,11 +29,32 @@ jobs:
- run: pip install -e .[toml] pytest
- run: pytest
+ check_selfinstall:
+ runs-on: ubuntu-latest
+ strategy:
+ fail-fast: false
+ matrix:
+ python_version: [ '2.7', '3.5', '3.6', '3.7', '3.8', 'pypy2', 'pypy3' ]
+ name: check self install - Python ${{ matrix.python_version }}
+ steps:
+ - uses: actions/checkout@v1
+ - name: Setup python
+ uses: actions/setup-python@v2
+ with:
+ python-version: ${{ matrix.python_version }}
+ architecture: x64
+ # self install testing needs some clarity
+ # so its being executed without any other tools running
+ - run: pip install -U setuptools
+ - run: python setup.py sdist
+ - run: easy_install dist/*
+ - run: python testing/check_self_install.py
+
eggs:
runs-on: ubuntu-latest
- needs: [build]
+ needs: [test]
name: Python ${{ matrix.python_version }} eggs
strategy:
matrix:
@@ -59,7 +80,7 @@ jobs:
dist:
runs-on: ubuntu-latest
- needs: [build]
+ needs: [test]
name: Python bdist/wheel
steps:
- uses: actions/checkout@v1
@@ -78,15 +99,32 @@ jobs:
name: dist
path: dist
+
+ dist_check:
+ runs-on: ubuntu-latest
+ needs: [eggs, dist]
+ steps:
+ - uses: actions/setup-python@v2
+ with:
+ python-version: "3.8"
+ - name: Install dependencies
+ run: pip install twine
+ - uses: actions/download-artifact@v2
+ with:
+ name: dist
+ path: dist
+ - run: twine check dist/*
+
dist_upload:
runs-on: ubuntu-latest
if: github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags') && github.repository == 'pypa/setuptools_scm'
- needs: [eggs, dist]
+ needs: [dist_check]
steps:
- uses: actions/download-artifact@v2
with:
name: dist
+ path: dist
- name: Publish package to PyPI
uses: pypa/gh-action-pypi-publish@master
with: