diff --git a/.github/workflows/test-ci.yml b/.github/workflows/test-ci.yml new file mode 100644 index 00000000..93061814 --- /dev/null +++ b/.github/workflows/test-ci.yml @@ -0,0 +1,31 @@ +# GitHub actions workflow. +# https://help.github.com/en/actions/automating-your-workflow-with-github-actions/workflow-syntax-for-github-actions + +name: Test CI + +on: + push: + branches: [master, repo-1, stable, maint] + tags: [v*] + +jobs: + test: + strategy: + fail-fast: false + matrix: + os: [ubuntu-latest, macos-latest, windows-latest] + python-version: [2.7, 3.6, 3.7, 3.8] + runs-on: ${{ matrix.os }} + + steps: + - uses: actions/checkout@v2 + - name: Set up Python ${{ matrix.python-version }} + uses: actions/setup-python@v1 + with: + python-version: ${{ matrix.python-version }} + - name: Install dependencies + run: | + python -m pip install --upgrade pip + pip install tox tox-gh-actions + - name: Test with tox + run: tox diff --git a/README.md b/README.md index 1e3c46ce..3989dde1 100644 --- a/README.md +++ b/README.md @@ -15,6 +15,8 @@ that you can put anywhere in your path. * [repo Hooks](./docs/repo-hooks.md) * [Submitting patches](./SUBMITTING_PATCHES.md) * Running Repo in [Microsoft Windows](./docs/windows.md) +* GitHub mirror: +* Postsubmit tests: ## Install diff --git a/tox.ini b/tox.ini index 1a9642a3..e6d38e76 100644 --- a/tox.ini +++ b/tox.ini @@ -17,6 +17,13 @@ [tox] envlist = py27, py36, py37, py38 +[gh-actions] +python = + 2.7: py27 + 3.6: py36 + 3.7: py37 + 3.8: py38 + [testenv] deps = pytest commands = {envpython} run_tests