hashicorp / terraform-provider-google

Terraform Provider for Google Cloud Platform
https://registry.terraform.io/providers/hashicorp/google/latest/docs
Mozilla Public License 2.0
2.33k stars 1.74k forks source link

Failing test(s): TestAccSecurityCenterV2ProjectBigQueryExportConfig_basic + others #20003

Open SarahFrench opened 2 weeks ago

SarahFrench commented 2 weeks ago

Impacted tests

Affected Resource(s)

Failure rates

Message(s)

------- Stdout: -------
=== RUN   TestAccSecurityCenterV2ProjectBigQueryExportConfig_basic
=== PAUSE TestAccSecurityCenterV2ProjectBigQueryExportConfig_basic
=== CONT  TestAccSecurityCenterV2ProjectBigQueryExportConfig_basic
    testing_new.go:90: Error running post-test destroy, there may be dangling resources: exit status 1
        Error: Error when reading or editing Dataset: googleapi: Error 400: Dataset ci-test-project-nightly-ga:tf_test_fbn2dql0rc is still in use, resourceInUse
--- FAIL: TestAccSecurityCenterV2ProjectBigQueryExportConfig_basic (210.52s)
FAIL

Nightly build test history

https://hashicorp.teamcity.com/test/2715200116441949818?currentProjectId=TerraformProviders_GoogleCloud_GOOGLE_NIGHTLYTESTS&expandTestHistoryChartSection=true&expandedTest=build%3A%28id%3A249228%29%2Cid%3A2000000012

b/375653701

wj-chen commented 2 weeks ago

Hi Sarah, do you have more details about the tests to show? We don't have access to the test history and I can't seem to find the test in the repo by searching by this name.

SarahFrench commented 2 weeks ago

Here's are the tests in the code:

https://github.com/hashicorp/terraform-provider-google/blob/a27d21902d1c9fd1b4043be00c441c1b4eb6ec14/google/services/securitycenterv2/resource_scc_v2_project_big_query_export_config_test.go#L14

https://github.com/hashicorp/terraform-provider-google/blob/a27d21902d1c9fd1b4043be00c441c1b4eb6ec14/google/services/securitycenterv2/resource_scc_v2_organization_big_query_export_config_test.go#L14

https://github.com/hashicorp/terraform-provider-google/blob/a27d21902d1c9fd1b4043be00c441c1b4eb6ec14/google/services/securitycenterv2/resource_scc_v2_organization_big_query_exports_config_test.go#L14

I don't have more details about the tests to show, but I believe there is a Google-internal way that nightly test logs are shared with people from the service team. I don't know the details myself- it might be worth checking with the Google Terraform team.

wj-chen commented 2 weeks ago

Thank you Sarah. I took a look and these tests should be about the google_scc_v2_organization_scc_big_query_export resource which is owned by the SCC team. The tests use google_bigquery_dataset in the setup and for some reasons are not cleaning it up consistently. Adding @roaks3 the terraform-team-oncall this week to help reroute the issue here and in our internal issue tracker.

SarahFrench commented 2 weeks ago

Sorry about that - I think the correct label would then be service/securitycenter but I'll defer to Ryan

roaks3 commented 2 weeks ago

Ah yep, ok, I'm going to close the previously forwarded issue, and then change the Affected Resource(s) block to forward to the correct team. Thanks for flagging!