huaweicloud / terraform-provider-huaweicloud

Terraform HuaweiCloud provider
https://www.terraform.io/docs/providers/huaweicloud/
Mozilla Public License 2.0
213 stars 160 forks source link

chore(vpn): replace the jmespath.Search method with the utils.PathSearch method #5551

Closed profoundwu closed 1 month ago

profoundwu commented 1 month ago

What this PR does / why we need it: replace the jmespath.Search method with the utils.PathSearch method Which issue this PR fixes: (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close that issue when PR gets merged) fixes #xxx

Special notes for your reviewer:

Release note:

1. replace the jmespath.Search method with the utils.PathSearch method

PR Checklist


make testacc TEST="./huaweicloud/services/acceptance/vpn" TESTARGS="-run TestAccConnection_basic"
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./huaweicloud/services/acceptance/vpn -v -run TestAccConnection_basic -timeout 360m -parallel 4
=== RUN   TestAccConnection_basic
=== PAUSE TestAccConnection_basic
=== CONT  TestAccConnection_basic
--- PASS: TestAccConnection_basic (504.16s)
PASS
ok      github.com/huaweicloud/terraform-provider-huaweicloud/huaweicloud/services/acceptance/vpn       504.225s

 make testacc TEST="./huaweicloud/services/acceptance/vpn" TESTARGS="-run TestAccConnectionHealthCheck_basic"
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./huaweicloud/services/acceptance/vpn -v -run TestAccConnectionHealthCheck_basic -timeout 360m -parallel 4
=== RUN   TestAccConnectionHealthCheck_basic
=== PAUSE TestAccConnectionHealthCheck_basic
=== CONT  TestAccConnectionHealthCheck_basic
--- PASS: TestAccConnectionHealthCheck_basic (418.43s)
PASS
ok      github.com/huaweicloud/terraform-provider-huaweicloud/huaweicloud/services/acceptance/vpn       418.501s

make testacc TEST="./huaweicloud/services/acceptance/vpn" TESTARGS="-run TestAccCustomerGateway_basic"  ==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./huaweicloud/services/acceptance/vpn -v -run TestAccCustomerGateway_basic -timeout 360m -parallel 4
=== RUN   TestAccCustomerGateway_basic_withDeprecatedFields
=== PAUSE TestAccCustomerGateway_basic_withDeprecatedFields
=== RUN   TestAccCustomerGateway_basic
=== PAUSE TestAccCustomerGateway_basic
=== CONT  TestAccCustomerGateway_basic_withDeprecatedFields
=== CONT  TestAccCustomerGateway_basic
--- PASS: TestAccCustomerGateway_basic (31.81s)
--- PASS: TestAccCustomerGateway_basic_withDeprecatedFields (32.44s)
PASS
ok      github.com/huaweicloud/terraform-provider-huaweicloud/huaweicloud/services/acceptance/vpn       32.498s

make testacc TEST="./huaweicloud/services/acceptance/vpn" TESTARGS="-run TestAccGateway_basic"
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./huaweicloud/services/acceptance/vpn -v -run TestAccGateway_basic -timeout 360m -parallel 4
=== RUN   TestAccGateway_basic
=== PAUSE TestAccGateway_basic
=== CONT  TestAccGateway_basic
--- PASS: TestAccGateway_basic (478.96s)
PASS
ok      github.com/huaweicloud/terraform-provider-huaweicloud/huaweicloud/services/acceptance/vpn       479.052s
houpeng80 commented 1 month ago

/lgtm

Jason-Zhang9309 commented 1 month ago

/approve