This repository was archived by the owner on May 17, 2024. It is now read-only.
File tree Expand file tree Collapse file tree 5 files changed +11
-14
lines changed Expand file tree Collapse file tree 5 files changed +11
-14
lines changed Original file line number Diff line number Diff line change 1
1
/kube-oidc-proxy
2
2
/bin
3
3
/demo /config.jsonnet
4
+ /artifacts /
Original file line number Diff line number Diff line change @@ -83,9 +83,12 @@ generate: depend ## generates mocks and assets files
83
83
go generate $$(go list ./pkg/... ./cmd/... )
84
84
85
85
test : generate verify # # run all go tests
86
- go test $$(go list ./pkg/... ./cmd/... | grep -v pkg/e2e )
86
+ mkdir -p artifacts
87
+ go test -v -bench $$(go list ./pkg/... ./cmd/... | grep -v pkg/e2e ) | tee artifacts/go-test.stdout
88
+ cat artifacts/go-test.stdout | go run github.com/jstemmer/go-junit-report > artifacts/junit-go-test.xml
87
89
88
90
e2e : # # run end to end tests
91
+ mkdir -p artifacts
89
92
KUBE_OIDC_PROXY_ROOT_PATH=" $$ (pwd)" go test -timeout 30m -v --count=1 ./test/e2e/suite/.
90
93
91
94
build : generate # # build kube-oidc-proxy
Original file line number Diff line number Diff line change 5
5
require (
6
6
github.com/golang/mock v1.2.0
7
7
github.com/heptiolabs/healthcheck v0.0.0-20180807145615-6ff867650f40
8
+ github.com/jstemmer/go-junit-report v0.9.1 // indirect
8
9
github.com/onsi/ginkgo v1.10.1
9
10
github.com/onsi/gomega v1.7.0
10
11
github.com/sirupsen/logrus v1.4.2
Original file line number Diff line number Diff line change @@ -150,6 +150,8 @@ github.com/json-iterator/go v1.1.6/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCV
150
150
github.com/json-iterator/go v1.1.7 h1:KfgG9LzI+pYjr4xvmz/5H4FXjokeP+rlHLhv3iH62Fo =
151
151
github.com/json-iterator/go v1.1.7 /go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4 =
152
152
github.com/jstemmer/go-junit-report v0.0.0-20190106144839-af01ea7f8024 /go.mod h1:6v2b51hI/fHJwM22ozAgKL4VKDeJcHhJFhtBdhmNjmU =
153
+ github.com/jstemmer/go-junit-report v0.9.1 h1:6QPYqodiu3GuPL+7mfx+NwDdp2eTkp9IfEUpgAwUN0o =
154
+ github.com/jstemmer/go-junit-report v0.9.1 /go.mod h1:Brl9GWCQeLvo8nXZwPNNblvFj/XSXhF0NWZEnDohbsk =
153
155
github.com/kisielk/errcheck v1.1.0 /go.mod h1:EZBBE59ingxPouuu3KfxchcWSUPOHkagtvWXihfKN4Q =
154
156
github.com/kisielk/errcheck v1.2.0 /go.mod h1:/BMXB+zMLi60iA8Vv6Ksmxu/1UDYcXs4uQLJ+jE2L00 =
155
157
github.com/kisielk/gotool v1.0.0 /go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck =
Original file line number Diff line number Diff line change 2
2
package suite
3
3
4
4
import (
5
- //"fmt"
6
- //"path"
7
5
"testing"
8
6
"time"
9
7
10
8
"github.com/onsi/ginkgo"
11
9
ginkgoconfig "github.com/onsi/ginkgo/config"
12
-
13
- //"github.com/onsi/ginkgo/reporters"
10
+ "github.com/onsi/ginkgo/reporters"
14
11
"github.com/onsi/gomega"
15
12
"k8s.io/apimachinery/pkg/util/wait"
16
13
@@ -31,13 +28,6 @@ func init() {
31
28
func TestE2E (t * testing.T ) {
32
29
gomega .RegisterFailHandler (ginkgo .Fail )
33
30
34
- var r []ginkgo.Reporter
35
- //if framework.DefaultConfig.Ginkgo.ReportDirectory != "" {
36
- // r = append(r, reporters.NewJUnitReporter(path.Join(framework.DefaultConfig.Ginkgo.ReportDirectory,
37
- // fmt.Sprintf("junit_%s_%02d.xml",
38
- // framework.DefaultConfig.Ginkgo.ReportPrefix,
39
- // ginkgoconfig.GinkgoConfig.ParallelNode))))
40
- //}
41
-
42
- ginkgo .RunSpecsWithDefaultAndCustomReporters (t , "kube-oidc-proxy e2e suite" , r )
31
+ junitReporter := reporters .NewJUnitReporter ("../../../artifacts/junit-go-e2e.xml" )
32
+ ginkgo .RunSpecsWithDefaultAndCustomReporters (t , "kube-oidc-proxy e2e suite" , []ginkgo.Reporter {junitReporter })
43
33
}
You can’t perform that action at this time.
0 commit comments