Skip to content

Commit

Permalink
Remove test step as the error has been fixed in backend (#4654) (#3117)
Browse files Browse the repository at this point in the history
* Remove test step as the error has been fixed in backend

* remove dead code :)

* Update resource_cloud_run_domain_mapping_test.go

remove error expectation but retain the config

* Update resource_cloud_run_domain_mapping_test.go

Add back function

Signed-off-by: Modular Magician <magic-modules@google.com>
  • Loading branch information
modular-magician authored Apr 3, 2021
1 parent 067bb4e commit da8ec57
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 13 deletions.
3 changes: 3 additions & 0 deletions .changelog/4654.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
```release-note:none

```
16 changes: 4 additions & 12 deletions google-beta/resource_cloud_run_domain_mapping_test.go
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package google

import (
"regexp"
"testing"

"github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource"
Expand Down Expand Up @@ -35,14 +34,13 @@ func TestAccCloudRunDomainMapping_foregroundDeletion(t *testing.T) {
},
{
Config: testAccCloudRunDomainMapping_cloudRunDomainMappingUpdated2(context),
ExpectError: regexp.MustCompile("Domain mapping already exists"), // when this error is no longer returned, remove ExpectError and add the ISV below.
},
/*{
{
ResourceName: "google_cloud_run_domain_mapping.default",
ImportState: true,
ImportStateVerify: true,
ImportStateVerifyIgnore: []string{"name", "location", "status", "metadata.0.resource_version"},
},*/
},
},
})
}
Expand All @@ -52,11 +50,11 @@ func testAccCloudRunDomainMapping_cloudRunDomainMappingUpdated1(context map[stri
resource "google_cloud_run_service" "default" {
name = "tf-test-cloudrun-srv%{random_suffix}"
location = "us-central1"
metadata {
namespace = "%{namespace}"
}
template {
spec {
containers {
Expand All @@ -83,15 +81,12 @@ resource "google_cloud_run_domain_mapping" "default" {

func testAccCloudRunDomainMapping_cloudRunDomainMappingUpdated2(context map[string]interface{}) string {
return Nprintf(`
resource "google_cloud_run_service" "default" {
name = "tf-test-cloudrun-srv%{random_suffix}"
location = "us-central1"
metadata {
namespace = "%{namespace}"
}
template {
spec {
containers {
Expand All @@ -100,18 +95,15 @@ resource "google_cloud_run_service" "default" {
}
}
}
resource "google_cloud_run_domain_mapping" "default" {
location = "us-central1"
name = "tf-test-domain%{random_suffix}.gcp.tfacc.hashicorptest.com"
metadata {
namespace = "%{namespace}"
labels = {
"my-label" = "my-value"
}
}
spec {
route_name = google_cloud_run_service.default.name
}
Expand Down
3 changes: 2 additions & 1 deletion google-beta/resource_dataproc_cluster_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,9 @@ import (
"github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource"
"github.com/hashicorp/terraform-plugin-sdk/v2/terraform"

dataproc "google.golang.org/api/dataproc/v1beta2"
"google.golang.org/api/googleapi"

dataproc "google.golang.org/api/dataproc/v1beta2"
)

func TestDataprocExtractInitTimeout(t *testing.T) {
Expand Down

0 comments on commit da8ec57

Please sign in to comment.