summaryrefslogtreecommitdiff
path: root/.github/workflows/ci.yaml
blob: f9bf49feb6440b3bf8b4e4c04d89b363d69fe313 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
name: CI
on: [push, pull_request]
jobs:
  build:
    strategy:
      matrix:
        python-version: ["3.8", "3.9", "3.10", "3.11.0-alpha - 3.11", "pypy-3.8", "pypy-3.9"]
        variant: ["", "-norequests-noresponses", "-noresponses"]
        gpg: ["no-gpg", "vanilla-gpg"]
      fail-fast: false
    runs-on: ubuntu-22.04
    steps:
      - name: Checkout
        uses: actions/checkout@v2
      - name: Set up Python
        uses: actions/setup-python@v3
        with:
          python-version: ${{ matrix.python-version }}
      - name: Uninstall GnuPG
        if: ${{ matrix.gpg == 'no-gpg' }}
        run: sudo apt remove gpg
      - name: Install vanilla GnuPG
        if: ${{ matrix.gpg == 'vanilla-gpg' }}
        run: |
          sudo apt install libassuan-dev libksba-dev libnpth-dev
          wget -q -O - https://gnupg.org/ftp/gcrypt/gnupg/gnupg-2.2.39.tar.bz2 | tar -xj
          cd gnupg-*/
          ./configure
          make -j2
          sudo make install
      - name: Install tox
        run: pip install tox
      - name: Test using tox
        run: tox -e py${{ matrix.variant }}
  qa:
    runs-on: ubuntu-22.04
    steps:
      - name: Checkout
        uses: actions/checkout@v2
      - name: Set up Python
        uses: actions/setup-python@v3
        with:
          python-version: "3.10"
      - name: Install tox
        run: pip install tox
      - name: Test using tox
        run: tox -e qa