Timothy J. Warren
87e742af5c
All checks were successful
timw4mail/gilo/pipeline/head This commit looks good
32 lines
635 B
Groovy
32 lines
635 B
Groovy
pipeline {
|
|
agent any
|
|
tools {
|
|
go 'go1.16.2'
|
|
}
|
|
environment {
|
|
GO114MODULE = 'on'
|
|
CGO_ENABLED = 0
|
|
GOPATH = "${JENKINS_HOME}/jobs/${JOB_NAME}/builds/${BUILD_ID}"
|
|
}
|
|
stages {
|
|
stage('Pre Test') {
|
|
steps {
|
|
echo 'Installing dependencies'
|
|
sh 'go version'
|
|
}
|
|
}
|
|
|
|
stage('Build') {
|
|
steps {
|
|
echo 'Compiling and building'
|
|
sh 'go build'
|
|
}
|
|
}
|
|
|
|
stage('Test') {
|
|
steps {
|
|
sh "go test ./... -v"
|
|
}
|
|
}
|
|
}
|
|
} |