-
Notifications
You must be signed in to change notification settings - Fork 6
/
Jenkinsfile
52 lines (49 loc) · 1.21 KB
/
Jenkinsfile
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
pipeline {
agent any
stages {
stage('Install Package') {
steps {
withPythonEnv('python3.10') {
sh 'python3.10 -mpip install .'
}
}
}
stage('Run Source Code Tests') {
parallel {
stage('flake8 check') {
agent {
dockerfile {
dir '.jenkins'
filename 'Dockerfile-flake8'
}
}
steps {
withPythonEnv('python3.10') {
sh 'python3.10 -mpip install --target ${WORKSPACE} flake8'
sh 'flake8 --exclude .git,__pycache__,node_modules,.pyenv* --count --statistics --ignore E227 /data'
}
}
}
stage('pydocstyle check') {
agent {
dockerfile {
dir '.jenkins'
filename 'Dockerfile-pydocstyle'
}
}
steps {
sh 'pydocstyle --convention=pep257 --count nextcloud_async || true'
sh 'docstr-coverage -P -m nextcloud_async'
}
}
stage('Unit testing') {
steps {
withPythonEnv('python3.10') {
sh 'python3.10 -m unittest'
}
}
}
}
}
}
}