Skip to content
This repository was archived by the owner on Nov 16, 2023. It is now read-only.

Commit f835d8c

Browse files
David Tesardcaro
authored andcommitted
Fix trips warnings (#65)
* fix export warnings * go mod tweak * Add testify to import * Remove duplicate testify package
1 parent 2367f1b commit f835d8c

3 files changed

Lines changed: 6 additions & 7 deletions

File tree

apis/trips/glide.yaml

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,5 @@ import:
55
- package: github.com/denisenkom/go-mssqldb
66
- package: github.com/gorilla/mux
77
version: ~1.6.2
8-
testImport:
98
- package: github.com/stretchr/testify
10-
version: ~1.2.2
11-
subpackages:
12-
- assert
9+
version: ~1.2.2

apis/trips/go.mod

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
module github.com/Azure-Samples/openhack-devops-team/apis/trips
22

33
require (
4-
cloud.google.com/go v0.0.0-20180627205256-45528feae6df
4+
cloud.google.com/go v0.0.0-20180627205256-45528feae6df // indirect
55
github.com/codemodus/swagui v0.1.0
66
github.com/davecgh/go-spew v1.1.1 // indirect
77
github.com/denisenkom/go-mssqldb v0.0.0-20180625034930-3724b4745ca9
8-
github.com/gorilla/context v1.1.1
8+
github.com/gorilla/context v1.1.1 // indirect
99
github.com/gorilla/mux v1.6.2
1010
github.com/pmezard/go-difflib v1.0.0 // indirect
1111
github.com/stretchr/objx v0.1.1 // indirect
1212
github.com/stretchr/testify v1.2.2
13-
golang.org/x/crypto v0.0.0-20180621125126-a49355c7e3f8
13+
golang.org/x/crypto v0.0.0-20180621125126-a49355c7e3f8 // indirect
1414
)

apis/trips/tripsgo/test_util.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ import (
1111
"github.com/stretchr/testify/assert"
1212
)
1313

14+
// APITestCase needs to be exported to be accessed for test dir
1415
type APITestCase struct {
1516
Tag string
1617
Method string
@@ -34,6 +35,7 @@ func testAPI(router *mux.Router, method, URL, body string) *httptest.ResponseRec
3435
return res
3536
}
3637

38+
// RunAPITests needs to be exported to be accessed for test dir
3739
func RunAPITests(t *testing.T, router *mux.Router, tests []APITestCase) {
3840
for i := 0; i < len(tests); i++ {
3941
res := testAPI(router, tests[i].Method, tests[i].URL, tests[i].Body)

0 commit comments

Comments
 (0)