-
Notifications
You must be signed in to change notification settings - Fork 208
91 lines (84 loc) · 3 KB
/
bugwarrior.yml
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
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
---
name: bugwarrior
on: [push, pull_request]
jobs:
bugwarrior-test:
runs-on: ubuntu-20.04
# We're currently seeing these complete in 1 minute.
timeout-minutes: 5
strategy:
matrix:
python-version: [3.8, 3.9, "3.10", 3.11]
jira-version: [1.0.10, 2.0.0]
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Set Jira version ${{ matrix.jira-version }}
run: echo "JIRAVERSION=${{ matrix.jira-version }}" >> $GITHUB_ENV
- name: Run tests
run: |
sudo apt-get update -qq
sudo apt-get install -qq -y \
libffi-dev libssl-dev pandoc python3-pip taskwarrior
task --version
pip3 install --upgrade pip
pip install codecov
pip install pytest-cov
pip3 install .[all]
pytest --cov=bugwarrior --cov-branch tests
flake8
- name: Coverage
uses: codecov/codecov-action@v1
with:
file: ./.coverage
# Fragile way to only run codecov once.
# See https://github.com/codecov/codecov-action/issues/40.
if: |
matrix.python-version == 3.9 &&
matrix.jira-version == '2.0.0'
bugwarrior-multiarch-test:
runs-on: ubuntu-20.04
# We're currently seeing these complete in 10-30 minutes.
timeout-minutes: 60
strategy:
matrix:
python-version: [3.8, 3.9, "3.10", 3.11]
jira-version: [1.0.10, 2.0.0]
architecture: [aarch64, ppc64le]
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Set Jira version ${{ matrix.jira-version }}
run: echo "JIRAVERSION=${{ matrix.jira-version }}" >> $GITHUB_ENV
- name: Run tests on given architecture
uses: uraimo/[email protected]
with:
arch: ${{ matrix.architecture }}
distro: ubuntu20.04
env: |
# https://github.com/PyO3/setuptools-rust/issues/236
CARGO_NET_GIT_FETCH_WITH_CLI: "true"
install: |
apt-get update -qq
# ppc64le lacks the rust compiler needed to install cryptography
# We can probably remove this once the pp64le image is updated.
apt-get install -qq -y curl
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
source $HOME/.cargo/env
apt-get install -qq -y \
git libffi-dev libjpeg-dev libssl-dev pandoc python3-pip taskwarrior
task --version
pip3 install --upgrade pip
run: |
source $HOME/.cargo/env
apt-get install -qq -y pkg-config libssl-dev
pip3 install .[all]
pytest