mirror of
https://github.com/restic/rest-server.git
synced 2025-10-19 07:33:21 +00:00
Travis: Fix tests (again)
The problem is that in Go < 1.9 "..." also matches the vendor directory, and we don't want to run those tests :)
This commit is contained in:
parent
ec7289235c
commit
a6961e877b
2 changed files with 9 additions and 6 deletions
|
@ -29,7 +29,7 @@ install:
|
|||
|
||||
script:
|
||||
- go install
|
||||
- go test -v ./...
|
||||
- go test -v . ./cmd/rest-server
|
||||
- go run build.go -v -T
|
||||
- diff <(goimports -d *.go) <(printf "")
|
||||
|
||||
|
|
13
build.go
13
build.go
|
@ -46,11 +46,14 @@ import (
|
|||
|
||||
// config contains the configuration for the program to build.
|
||||
var config = Config{
|
||||
Name: "rest-server", // name of the program executable and directory
|
||||
Namespace: "github.com/restic/rest-server", // subdir of GOPATH, e.g. "github.com/foo/bar"
|
||||
Main: "github.com/restic/rest-server/cmd/rest-server", // package name for the main package
|
||||
Tests: []string{"github.com/restic/rest-server/..."}, // tests to run
|
||||
MinVersion: GoVersion{Major: 1, Minor: 7, Patch: 0}, // minimum Go version supported
|
||||
Name: "rest-server", // name of the program executable and directory
|
||||
Namespace: "github.com/restic/rest-server", // subdir of GOPATH, e.g. "github.com/foo/bar"
|
||||
Main: "github.com/restic/rest-server/cmd/rest-server", // package name for the main package
|
||||
Tests: []string{ // tests to run
|
||||
"github.com/restic/rest-server",
|
||||
"github.com/restic/rest-server/cmd/rest-server",
|
||||
},
|
||||
MinVersion: GoVersion{Major: 1, Minor: 7, Patch: 0}, // minimum Go version supported
|
||||
}
|
||||
|
||||
// Config configures the build.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue