File tree Expand file tree Collapse file tree 4 files changed +31
-82
lines changed
Expand file tree Collapse file tree 4 files changed +31
-82
lines changed Original file line number Diff line number Diff line change 99- go fmt $(go list ./... | grep -v vendor) | wc -l | grep 0
1010- go vet $(go list ./... | grep -v vendor)
1111- go test $(go list ./... | grep -v vendor | grep -v "cmd/csi-sanity")
12+ - ./hack/e2e.sh
Original file line number Diff line number Diff line change @@ -24,6 +24,9 @@ all: $(APP_NAME)
2424$(APP_NAME ) : Makefile sanity_test.go
2525 go test $(LDFLAGS ) -c -o $(APP_NAME )
2626
27+ install : $(APP_NAME )
28+ cp $(APP_NAME ) $(GOPATH ) /bin
29+
2730clean :
2831 rm -f csi-sanity
2932 rm -rf $(DIR ) /dist
Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+
3+ CSI_ENDPOINTS=" tcp://127.0.0.1:9998"
4+ # CSI_ENDPOINTS="$CSI_ENDPOINTS /tmp/csi.sock"
5+ # CSI_ENDPOINTS="$CSI_ENDPOINTS unix:///tmp/csi.sock"
6+
7+ if [ ! -x $GOPATH /bin/mock ] ; then
8+ go get -u github.com/thecodeteam/gocsi/mock
9+ fi
10+
11+ cd cmd/csi-sanity
12+ make clean install || exit 1
13+ cd ../..
14+
15+ for endpoint in $CSI_ENDPOINTS ; do
16+ CSI_ENDPOINT=$endpoint mock &
17+ pid=$!
18+
19+ csi-sanity --csi.endpoint=$endpoint ; ret=$?
20+ kill -9 $pid
21+
22+ if [ $ret -ne 0 ] ; then
23+ exit $ret
24+ fi
25+ done
26+
27+ exit 0
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments