-
Notifications
You must be signed in to change notification settings - Fork 20
Expand file tree
/
Copy pathMakefile
More file actions
31 lines (28 loc) · 785 Bytes
/
Makefile
File metadata and controls
31 lines (28 loc) · 785 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
.PHONY: build
build:
docker build -t contentful-terraform-test -f Dockerfile-test .
.PHONY: test-unit
test-unit: build
docker run \
contentful-terraform-test \
go test -v
# Runs an end-to-end integration test using Contentful.
# Requires that the following environment variables are set:
# - CONTENTFUL_MANAGEMENT_TOKEN
# - CONTENTFUL_ORGANIZATION_ID
.PHONY: test-integration
test-integration: build
docker run \
-e CONTENTFUL_MANAGEMENT_TOKEN \
-e CONTENTFUL_ORGANIZATION_ID \
-e "TF_ACC=true" \
contentful-terraform-test \
go test -v
.PHONY: interactive
interactive:
docker run -it \
-v $(shell pwd):/go/src/github.com/danihodovic/contentful-terraform \
-e CONTENTFUL_MANAGEMENT_TOKEN \
-e CONTENTFUL_ORGANIZATION_ID \
contentful-terraform-test \
bash