Browse Source

run test in azure pipeline

pull/1435/head
Darien Raymond 6 years ago
parent
commit
ab7930c09b
No known key found for this signature in database
GPG Key ID: 7251FFA14BB18169
  1. 11
      azure-pipelines.yml

11
azure-pipelines.yml

@ -7,15 +7,11 @@ pool:
vmImage: 'Ubuntu 16.04'
variables:
GOBIN: '$(GOPATH)/bin' # Go binaries path
GOROOT: '/usr/local/go1.11' # Go installation path
GOPATH: '$(system.defaultWorkingDirectory)/gopath' # Go workspace path
modulePath: '$(GOPATH)/src/v2ray.com/core' # Path to the module's code
steps:
- script: |
mkdir -p '$(GOBIN)'
mkdir -p '$(GOPATH)/pkg'
mkdir -p '$(modulePath)'
shopt -s extglob
mv !(gopath) '$(modulePath)'
@ -24,12 +20,9 @@ steps:
displayName: 'Set up the Go workspace'
- script: |
set -x
go version
go get -v -t -d ./...
if [ -f Gopkg.toml ]; then
curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh
dep ensure
fi
go build -v .
go test -p 1 -tags json -v v2ray.com/core/...
workingDirectory: '$(modulePath)'
displayName: 'Get dependencies, then build'

Loading…
Cancel
Save