summaryrefslogtreecommitdiff
path: root/.github/workflows/run-test.yaml
diff options
context:
space:
mode:
authorFederico Caselli <cfederico87@gmail.com>2021-10-26 20:33:17 +0200
committerFederico Caselli <cfederico87@gmail.com>2021-10-26 20:33:42 +0200
commitdff7bee0a2ee9d5a41fc2d285f7cf12d1432fd83 (patch)
tree455c29d7ca886090a6971924a15f43390b21de0f /.github/workflows/run-test.yaml
parentcf605c0994149b1a1936b3a8a597203fe3fbb62e (diff)
downloadpython-mimeparse-dff7bee0a2ee9d5a41fc2d285f7cf12d1432fd83.tar.gz
Add github actions
Fixes: #39
Diffstat (limited to '.github/workflows/run-test.yaml')
-rw-r--r--.github/workflows/run-test.yaml72
1 files changed, 72 insertions, 0 deletions
diff --git a/.github/workflows/run-test.yaml b/.github/workflows/run-test.yaml
new file mode 100644
index 0000000..a86fd17
--- /dev/null
+++ b/.github/workflows/run-test.yaml
@@ -0,0 +1,72 @@
+name: Run tests
+
+on:
+ push:
+ pull_request:
+
+
+jobs:
+ run-test:
+ name: test-${{ matrix.python-version }}
+ runs-on: "ubuntu-latest"
+ strategy:
+ matrix:
+ python-version:
+ - "3.6"
+ - "3.7"
+ - "3.8"
+ - "3.9"
+ - "3.10"
+ - "pypy-3.7"
+
+ fail-fast: false
+
+ steps:
+ - name: Checkout repo
+ uses: actions/checkout@v2
+
+ - name: Set up python
+ uses: actions/setup-python@v2
+ with:
+ python-version: ${{ matrix.python-version }}
+ architecture: ${{ matrix.architecture }}
+
+ - name: Install dependencies
+ run: |
+ python -m pip install --upgrade pip
+ pip install --upgrade tox setuptools
+ pip list
+
+ - name: Run tests
+ run: |
+ tox
+
+ run-test:
+ name: lint
+ runs-on: "ubuntu-latest"
+ strategy:
+ matrix:
+ python-version:
+ - "3.10"
+
+ fail-fast: false
+
+ steps:
+ - name: Checkout repo
+ uses: actions/checkout@v2
+
+ - name: Set up python
+ uses: actions/setup-python@v2
+ with:
+ python-version: ${{ matrix.python-version }}
+ architecture: ${{ matrix.architecture }}
+
+ - name: Install dependencies
+ run: |
+ python -m pip install --upgrade pip
+ pip install --upgrade tox setuptools
+ pip list
+
+ - name: Run tests
+ run: |
+ tox -e flake8