forked from DIRACGrid/Pilot
-
Notifications
You must be signed in to change notification settings - Fork 0
91 lines (76 loc) · 2.17 KB
/
basic.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: Basic tests
on: [push, pull_request]
jobs:
shellcheck:
runs-on: ubuntu-20.04
if: github.event_name != 'push' || github.repository == 'DIRACGrid/DIRAC'
timeout-minutes: 10
steps:
- uses: actions/checkout@v3
- name: Run shellcheck
run: |
find tests/CI -name '*.sh' -print0 | xargs -0 -n1 shellcheck --external-sources;
pycodestyle:
runs-on: ubuntu-20.04
if: github.event_name != 'push' || github.repository == 'DIRACGrid/Pilot'
timeout-minutes: 10
strategy:
matrix:
python:
- 2.7.18
- 3.6.15
- 3.9.17
container: python:${{ matrix.python }}-slim
steps:
- uses: actions/checkout@v3
- name: Installing dependencies
run: |
python -m pip install pycodestyle
- name: Run pycodestyle
run: |
if [[ "${REFERENCE_BRANCH}" != "" ]]; then
git remote add upstream https://github.com/DIRACGrid/Pilot.git
git fetch --no-tags upstream "${REFERENCE_BRANCH}"
git branch -vv
git diff -U0 "upstream/${REFERENCE_BRANCH}" | pycodestyle --diff
fi
env:
REFERENCE_BRANCH: ${{ github['base_ref'] || github['head_ref'] }}
pytest:
runs-on: ubuntu-20.04
if: github.event_name != 'push' || github.repository == 'DIRACGrid/Pilot'
timeout-minutes: 10
strategy:
matrix:
python:
- 2.7.18
- 3.6.15
- 3.9.17
container: python:${{ matrix.python }}-slim
steps:
- uses: actions/checkout@v3
- name: Installing dependencies
run: |
python -m pip install pytest mock
apt-get update
apt install -y voms-clients
- name: Run pytest
run: pytest
pylint:
runs-on: ubuntu-20.04
if: github.event_name != 'push' || github.repository == 'DIRACGrid/Pilot'
timeout-minutes: 10
strategy:
matrix:
python:
- 2.7.18
- 3.6.15
- 3.9.17
container: python:${{ matrix.python }}-slim
steps:
- uses: actions/checkout@v3
- name: Installing dependencies
run: |
python -m pip install pylint
- name: Run pylint
run: pylint -E Pilot/