Commit 91d1859 1 parent 8732efc commit 91d1859 Copy full SHA for 91d1859
File tree 1 file changed +44
-0
lines changed
1 file changed +44
-0
lines changed Original file line number Diff line number Diff line change
1
+ pipeline {
2
+ agent { label ' pr' }
3
+
4
+ options {
5
+ timestamps()
6
+ timeout(time : 1 , unit : ' HOURS' )
7
+ disableConcurrentBuilds(abortPrevious : true )
8
+ }
9
+
10
+ tools { go ' 1.21' }
11
+
12
+ stages {
13
+ stage(' Validate commit' ) {
14
+ steps {
15
+ script {
16
+ def CHANGE_REPO = sh(script : ' basename -s .git `git config --get remote.origin.url`' , returnStdout : true ). trim()
17
+ build job : ' /Utils/Validate-Git-Commit' , parameters : [
18
+ string(name : ' Repo' , value : " ${ CHANGE_REPO} " ),
19
+ string(name : ' Branch' , value : " ${ env.CHANGE_BRANCH} " ),
20
+ string(name : ' Commit' , value : " ${ GIT_COMMIT} " )
21
+ ]
22
+ }
23
+ }
24
+ }
25
+
26
+ stage(' Build' ) {
27
+ steps {
28
+ sh ' make'
29
+ }
30
+ }
31
+
32
+ stage(' Run tests' ) {
33
+ steps {
34
+ sh ' go test ./... --timeout 30m'
35
+ }
36
+ }
37
+
38
+ stage(' Clean up' ) {
39
+ steps {
40
+ sh ' make clean'
41
+ }
42
+ }
43
+ }
44
+ }
You can’t perform that action at this time.
0 commit comments