Skip to content

Commit

Permalink
Convert tests to plain go tests
Browse files Browse the repository at this point in the history
Signed-off-by: Juraci Paixão Kröhling <juraci@kroehling.de>
  • Loading branch information
jpkrohling committed Nov 16, 2020
1 parent 70787de commit 037e56f
Show file tree
Hide file tree
Showing 34 changed files with 1,727 additions and 1,813 deletions.
23 changes: 5 additions & 18 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -34,19 +34,19 @@ endif
# by default, do not run the manager with webhooks enabled. This only affects local runs, not the build or in-cluster deployments.
ENABLE_WEBHOOKS ?= false

# If we are running in CI, run ginkgo with the recommended CI settings
# If we are running in CI, run go test in verbose mode
ifeq (,$(CI))
GINKGO_OPTS=-r
GOTEST_OPTS=-race
else
GINKGO_OPTS=-r --randomizeAllSpecs --randomizeSuites --failOnPending --cover --trace --race --progress --compilers=2 -v
GOTEST_OPTS=-race -v
endif

all: manager
ci: test

# Run tests
test: ginkgo generate fmt vet manifests
$(GINKGO) $(GINKGO_OPTS)
test: generate fmt vet manifests
go test ${GOTEST_OPTS} ./...

# Build manager binary
manager: generate fmt vet
Expand Down Expand Up @@ -125,19 +125,6 @@ else
CONTROLLER_GEN=$(shell which controller-gen)
endif

# find or download ginkgo
# download ginkgo if necessary
ginkgo:
ifeq (, $(shell which ginkgo))
@{ \
set -e ;\
go get github.com/onsi/ginkgo/ginkgo@v1.14.2 ;\
}
GINKGO=$(GOBIN)/ginkgo
else
GINKGO=$(shell which ginkgo)
endif

kustomize:
ifeq (, $(shell which kustomize))
@{ \
Expand Down
Loading

0 comments on commit 037e56f

Please sign in to comment.