Skip to content

Commit

Permalink
Use github actions for test matrix (#11)
Browse files Browse the repository at this point in the history
* try github actions out

* try click version matrix

* Python 3.4+

* 3.8+

* add 3.7

* try 3.4 on 20.04

* 3.6

* try a different matrix

* why wont this run

* test actions again

* add more versions

* 8.1.4 is not relased yet

* add more versions

* iterate...

* Add a py2 version

* add more versions

* update readme

* Fix click-version typo
  • Loading branch information
whwright authored Mar 3, 2023
1 parent aab1c29 commit 3f9c7f0
Show file tree
Hide file tree
Showing 2 changed files with 51 additions and 1 deletion.
48 changes: 48 additions & 0 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
name: build and test

on: [push]

jobs:
build:

runs-on: ubuntu-latest
strategy:
matrix:

python-version: [
# "3.6", # TODO: Error: The version '3.6' with architecture 'x64' was not found for Ubuntu 22.04.
"3.7",
"3.8",
"3.9",
"3.10",
"3.11"
]
click-version: [
"5.1",
"6.7",
"7.0",
"7.1.2",
"8.0.4",
"8.1.3",
]
exclude:
# click 8.1 drops support for py36
- python-version: "3.6"
click-version: "8.1.3"


steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install package
run: |
python -m pip install --upgrade pip
pip install click==${{ matrix.click-version }}
python setup.py install
- name: Verify click version
run: pip freeze click
- name: Run tests
run: python -m unittest discover -v
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,9 @@ Installation
pip install click-command-tree
```

Tested against Python 3.4, 3.5, and 3.6 and click >= 5.0
This is tested against Python versions 3.7 - 3.11 and (latest major release) click versions
5.x, 6.x, 7.x, 7.1.x, 8.0.x, and 8.1.x.


Example
-------
Expand Down

0 comments on commit 3f9c7f0

Please sign in to comment.