Skip to content

Commit

Permalink
[CI] Split test and build
Browse files Browse the repository at this point in the history
  • Loading branch information
Mongey committed Apr 14, 2019
1 parent 771b918 commit 5495b62
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 7 deletions.
20 changes: 14 additions & 6 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,18 @@
version: 2
jobs:
build:
working_directory: /go/src/github.com/Mongey/terraform-provider-kafka
docker:
- image: circleci/golang:1.11
environment:
TEST_RESULTS: /tmp/test-results
steps:
- checkout
- run: go build
- store_artifacts:
path: /go/src/github.com/Mongey/terraform-provider-kafka/terraform-provider-kafka
destination: terraform-provider-kafka
test:
working_directory: /go/src/github.com/Mongey/terraform-provider-kafka
docker:
- image: circleci/golang:1.11
Expand All @@ -18,11 +30,6 @@ jobs:
KAFKA_LOG_SEGMENT_BYTES: 1234
steps:
- checkout
- run: go build
- store_artifacts:
path: /go/src/github.com/Mongey/terraform-provider-kafka/terraform-provider-kafka
destination: terraform-provider-kafka
- run: make test
- run: go get github.com/jstemmer/go-junit-report
- run: mkdir -p $TEST_RESULTS
- run:
Expand All @@ -35,6 +42,7 @@ jobs:

workflows:
version: 2
build:
build-and-test:
jobs:
- build
- test
3 changes: 2 additions & 1 deletion GNUmakefile
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ testacc:
KAFKA_CLIENT_KEY=../secrets/kafkacat-raw-private-key.pem \
KAFKA_SKIP_VERIFY=true \
KAFKA_ENABLE_TLS=true \
TG_LOG=debug TF_ACC=1 go test $(TEST) -v $(TESTARGS) -timeout 120m
TF_LOG=DEBUG \
TF_ACC=1 go test $(TEST) -v $(TESTARGS) -timeout 120m

.PHONY: build test testacc

0 comments on commit 5495b62

Please sign in to comment.