Skip to content

Commit bfd3c3c

Browse files
committed
Makefile: Set GO111MODULE=on for consistency, adjust tests accordingly
1 parent 692dacb commit bfd3c3c

File tree

6 files changed

+220
-9
lines changed

6 files changed

+220
-9
lines changed

.travis.yml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,6 @@ go:
44
- 1.11.x
55
- 1.12.x
66

7-
before_script:
8-
- go get github.com/valyala/quicktemplate
9-
107
script: make check_generated test
118

129
after_success:

Makefile

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,11 @@
1+
export GO111MODULE = on
2+
13
test: build
24
GL_TEST_RUN=1 ./golangci-lint run -v
35
GL_TEST_RUN=1 ./golangci-lint run --fast --no-config -v --skip-dirs 'test/testdata_etc,pkg/golinters/goanalysis/(checker|passes)'
46
GL_TEST_RUN=1 ./golangci-lint run --no-config -v --skip-dirs 'test/testdata_etc,pkg/golinters/goanalysis/(checker|passes)'
57
GL_TEST_RUN=1 go test -v ./...
8+
cd test && GL_TEST_RUN=1 go test -v ./...
69

710
build:
811
go build -o golangci-lint ./cmd/golangci-lint
@@ -31,9 +34,9 @@ release:
3134
curl -sL https://git.io/goreleaser | bash
3235

3336
update_deps:
34-
GO111MODULE=on go mod verify
35-
GO111MODULE=on go mod tidy
37+
go mod verify
38+
go mod tidy
3639
rm -rf vendor
37-
GO111MODULE=on go mod vendor
40+
go mod vendor
3841

3942
.PHONY: test

test/go.mod

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
module github.com/golangci/golangci-lint/test
2+
3+
replace github.com/golangci/golangci-lint => ../
4+
5+
require (
6+
github.com/golangci/golangci-lint v0.0.0-00010101000000-000000000000
7+
github.com/mitchellh/go-ps v0.0.0-20170309133038-4fdf99ab2936
8+
github.com/shirou/gopsutil v2.18.12+incompatible
9+
github.com/stretchr/testify v1.3.0
10+
github.com/valyala/quicktemplate v1.1.1
11+
gopkg.in/yaml.v2 v2.2.2
12+
)

0 commit comments

Comments
 (0)