Skip to content

Commit

Permalink
fix: Add missing test deps
Browse files Browse the repository at this point in the history
  • Loading branch information
bryantbiggs committed Jan 10, 2025
1 parent 26f8c29 commit 7e205f8
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -73,10 +73,12 @@ endif

.PHONY: lint
lint: ## Run linter over the codebase
go install github.com/golangci/golangci-lint/cmd/golangci-lint
golangci-lint run --timeout=30m

.PHONY: test
test: ## Lint, generate and run unit tests. Also ensure that integration tests compile
go install github.com/cloudflare/cfssl/cmd/...@latest
$(MAKE) lint
$(MAKE) unit-test
$(MAKE) build-integration-test
Expand All @@ -86,18 +88,20 @@ unit-test: check-all-generated-files-up-to-date unit-test-no-generate

.PHONY: unit-test-no-generate ## Run unit test only
unit-test-no-generate:
go install github.com/cloudflare/cfssl/cmd/...@latest
CGO_ENABLED=0 go test -tags=release ./pkg/... ./cmd/... $(UNIT_TEST_ARGS)

.PHONY: unit-test-race
unit-test-race: ## Run unit test with race detection
go install github.com/cloudflare/cfssl/cmd/...@latest
CGO_ENABLED=1 go test -race ./pkg/... ./cmd/... $(UNIT_TEST_ARGS)

.PHONY: build-integration-test
build-integration-test: $(all_generated_code) ## Ensure integration tests compile
@# Compile integration test binary without running any.
@# Required as build failure aren't listed when running go build below. See also: https://github.com/golang/go/issues/15513
go test -tags integration -run=^$$ ./integration/...
@# Build integration test binary:
@# Build integration test binary:
go build -tags integration -o ./eksctl-integration-test ./integration/main.go

.PHONY: integration-test
Expand Down Expand Up @@ -177,7 +181,6 @@ $(generated_code_deep_copy_helper): $(deep_copy_helper_input) ## Generate Kuber
$(generated_code_aws_sdk_mocks): $(call godeps,pkg/eks/mocks/mocks.go) ## Generate AWS SDK mocks
AWS_SDK_GO_DIR=$(AWS_SDK_GO_DIR) go generate ./pkg/eks/mocks


.PHONY: generate-kube-reserved
generate-kube-reserved: ## Update instance list with respective specs
@cd ./pkg/nodebootstrap/ && go run reserved_generate.go
Expand All @@ -195,4 +198,3 @@ prepare-release-candidate: ## Create release candidate
.PHONY: print-version
print-version: ## Prints the upcoming release number
@go run pkg/version/generate/release_generate.go print-version

0 comments on commit 7e205f8

Please sign in to comment.