@@ -14,16 +14,19 @@ If you want to contribute to Terraform Google Conversion, check out the
14
14
15
15
## Testing
16
16
17
- The read test(one of the unit tests) and integration test installs the provider
18
- binary and creates a terraform dev override file tf-dev-override.tfrc.
19
- [ Dev override] ( https://googlecloudplatform.github.io/magic-modules/develop/run-tests/#optional-test-manually )
20
- is to make sure the test runs against the provider version specified in the go
21
- module. You can place your own config to point to a different go binary
22
- destination within tf-dev-override.tfrc. If the file already exists, it will not
23
- be overwritten.
17
+ The [ read test] ( ../../tfplan2cai/test/read_test.go ) and integration test apply
18
+ [ dev override] ( https://googlecloudplatform.github.io/magic-modules/develop/run-tests/#optional-test-manually )
19
+ to make sure the test runs against the provider version specified in the go
20
+ module.
24
21
25
- It is better to run both the unit test and integration tests inside a Docker
26
- container to match the CI/CD pipeline.
22
+ The dev override configuration installs the provider binary into GOPATH/bin and
23
+ creates a terraform dev override file tf-dev-override.tfrc. You can create your
24
+ tf-dev-override.tfrc with your go binary destination. If the file already
25
+ exists, it will not be overwritten.
26
+
27
+ It is better to run both the unit test and integration tests inside the Docker
28
+ container to match the CI/CD pipeline, where the docker image has a
29
+ pre-installed terraform binary.
27
30
28
31
** Note:** Integration tests require a test project.
29
32
@@ -41,8 +44,8 @@ make run-docker
41
44
42
45
### Unit Test
43
46
44
- The read test( tfplan2cai/test/read_test.go) runs terraform binary to generate
45
- ` .tfplan.json ` files. It requires gcloud credential during that process .
47
+ Unit tests include [ read test] ( ../../ tfplan2cai/test/read_test.go) , which runs
48
+ terraform binary to generate ` .tfplan.json ` files.
46
49
47
50
``` bash
48
51
# Inside the docker container,
0 commit comments