Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add datasource to google_compute_security_policy resource #10780

Conversation

maxi-cit
Copy link
Contributor

Fixes: hashicorp/terraform-provider-google#3321

Release Note Template for Downstream PRs (will be copied)

`google_compute_security_policy`

@github-actions github-actions bot requested a review from c2thorn May 23, 2024 18:30
Copy link

Hello! I am a robot. Tests will require approval from a repository maintainer to run.

@c2thorn, a repository maintainer, has been assigned to review your changes. If you have not received review feedback within 2 business days, please leave a comment on this PR asking them to take a look.

You can help make sure that review is quick by doing a self-review and by running impacted tests locally.

@modular-magician modular-magician added the awaiting-approval Pull requests that needs reviewer's approval to run presubmit tests label May 23, 2024
Copy link

This PR has been waiting for review for 2 weekdays. Please take a look! Use the label disable-review-reminders to disable these notifications.

@maxi-cit
Copy link
Contributor Author

Hello @c2thorn could you run the tests please?

…oogle-compute-security-policy

sync merge upstream/main
@modular-magician modular-magician added service/compute-security-policy and removed awaiting-approval Pull requests that needs reviewer's approval to run presubmit tests labels May 29, 2024
@modular-magician
Copy link
Collaborator

Hi there, I'm the Modular magician. I've detected the following information about your changes:

Diff report

Your PR generated some diffs in downstreams - here they are.

google provider: Diff ( 4 files changed, 187 insertions(+))
google-beta provider: Diff ( 4 files changed, 187 insertions(+))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 938
Passed tests: 825
Skipped tests: 72
Affected tests: 41

Click here to see the affected service packages
  • compute

Action taken

Found 41 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
TestAccComputeAutoscaler_autoscalerBasicExample|TestAccComputeAutoscaler_autoscalerSingleInstanceExample|TestAccComputeAutoscaler_multicondition|TestAccComputeAutoscaler_scaleDownControl|TestAccComputeAutoscaler_scaleInControl|TestAccComputeAutoscaler_scaleInControlFixed|TestAccComputeAutoscaler_scalingSchedule|TestAccComputeAutoscaler_update|TestAccComputeBackendService_withBackendAndIAP|TestAccComputeInstanceGroup_rename|TestAccComputeInstanceNetworkIntefaceWithSecurityPolicy|TestAccComputeInstanceTemplate_sourceImageEncryptionKey|TestAccComputeInstance_guestAccelerator|TestAccComputePerInstanceConfig_removeInstanceOnDestroy|TestAccComputePerInstanceConfig_statefulIps|TestAccComputePerInstanceConfig_update|TestAccComputeRegionAutoscaler_regionAutoscalerBasicExample|TestAccComputeRegionAutoscaler_scaleDownControl|TestAccComputeRegionAutoscaler_scaleInControl|TestAccComputeRegionAutoscaler_scalingSchedule|TestAccComputeRegionAutoscaler_update|TestAccComputeRegionInstanceTemplate_sourceImageEncryptionKey|TestAccComputeTargetPool_basic|TestAccDataSourceComputeSecurityPolicy_basic|TestAccInstanceGroupManager_autoHealingPolicies|TestAccInstanceGroupManager_basic|TestAccInstanceGroupManager_resourceManagerTags|TestAccInstanceGroupManager_self_link_unique|TestAccInstanceGroupManager_stateful|TestAccInstanceGroupManager_targetSizeZero|TestAccInstanceGroupManager_update|TestAccInstanceGroupManager_versions|TestAccInstanceGroupManager_waitForStatus|TestAccRegionInstanceGroupManager_autoHealingPolicies|TestAccRegionInstanceGroupManager_basic|TestAccRegionInstanceGroupManager_distributionPolicy|TestAccRegionInstanceGroupManager_resourceManagerTags|TestAccRegionInstanceGroupManager_stateful|TestAccRegionInstanceGroupManager_targetSizeZero|TestAccRegionInstanceGroupManager_update|TestAccRegionInstanceGroupManager_versions

Get to know how VCR tests work

@modular-magician
Copy link
Collaborator

$\textcolor{green}{\textsf{Tests passed during RECORDING mode:}}$
TestAccComputeAutoscaler_autoscalerBasicExample[Debug log]
TestAccComputeAutoscaler_autoscalerSingleInstanceExample[Debug log]
TestAccComputeAutoscaler_multicondition[Debug log]
TestAccComputeAutoscaler_scaleDownControl[Debug log]
TestAccComputeAutoscaler_scaleInControl[Debug log]
TestAccComputeAutoscaler_scaleInControlFixed[Debug log]
TestAccComputeAutoscaler_scalingSchedule[Debug log]
TestAccComputeAutoscaler_update[Debug log]
TestAccComputeBackendService_withBackendAndIAP[Debug log]
TestAccComputeInstanceGroup_rename[Debug log]
TestAccComputeInstanceTemplate_sourceImageEncryptionKey[Debug log]
TestAccComputePerInstanceConfig_removeInstanceOnDestroy[Debug log]
TestAccComputePerInstanceConfig_statefulIps[Debug log]
TestAccComputePerInstanceConfig_update[Debug log]
TestAccComputeRegionAutoscaler_regionAutoscalerBasicExample[Debug log]
TestAccComputeRegionAutoscaler_scaleDownControl[Debug log]
TestAccComputeRegionAutoscaler_scaleInControl[Debug log]
TestAccComputeRegionAutoscaler_scalingSchedule[Debug log]
TestAccComputeRegionAutoscaler_update[Debug log]
TestAccComputeRegionInstanceTemplate_sourceImageEncryptionKey[Debug log]
TestAccComputeTargetPool_basic[Debug log]
TestAccDataSourceComputeSecurityPolicy_basic[Debug log]
TestAccInstanceGroupManager_autoHealingPolicies[Debug log]
TestAccInstanceGroupManager_basic[Debug log]
TestAccInstanceGroupManager_resourceManagerTags[Debug log]
TestAccInstanceGroupManager_self_link_unique[Debug log]
TestAccInstanceGroupManager_stateful[Debug log]
TestAccInstanceGroupManager_targetSizeZero[Debug log]
TestAccInstanceGroupManager_update[Debug log]
TestAccInstanceGroupManager_versions[Debug log]
TestAccInstanceGroupManager_waitForStatus[Debug log]
TestAccRegionInstanceGroupManager_autoHealingPolicies[Debug log]
TestAccRegionInstanceGroupManager_basic[Debug log]
TestAccRegionInstanceGroupManager_distributionPolicy[Debug log]
TestAccRegionInstanceGroupManager_resourceManagerTags[Debug log]
TestAccRegionInstanceGroupManager_stateful[Debug log]
TestAccRegionInstanceGroupManager_targetSizeZero[Debug log]
TestAccRegionInstanceGroupManager_update[Debug log]
TestAccRegionInstanceGroupManager_versions[Debug log]

$\textcolor{green}{\textsf{No issues found for passed tests after REPLAYING rerun.}}$


$\textcolor{red}{\textsf{Tests failed during RECORDING mode:}}$
TestAccComputeInstanceNetworkIntefaceWithSecurityPolicy[Error message] [Debug log]
TestAccComputeInstance_guestAccelerator[Error message] [Debug log]

$\textcolor{red}{\textsf{Please fix these to complete your PR.}}$
View the build log or the debug log for each test

@c2thorn
Copy link
Member

c2thorn commented May 29, 2024

Looks like the resource code needs to be formatted:

gofmt needs running on the following files:
./google-beta/services/compute/data_source_compute_secutity_policy_test.go
You can use the command: `make fmt` to reformat code.

Copy link
Member

@c2thorn c2thorn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please see the above comment

…oogle-compute-security-policy

sync merge from upstream/main
@github-actions github-actions bot requested a review from c2thorn May 29, 2024 22:59
@modular-magician modular-magician added the awaiting-approval Pull requests that needs reviewer's approval to run presubmit tests label May 29, 2024
@maxi-cit
Copy link
Contributor Author

Hello @c2thorn I updated the PR with the lint fixes. I saw that the test I am adding is passing but I do not know why other tests are failing. is these something related to newest changes in the repo?

@c2thorn
Copy link
Member

c2thorn commented May 30, 2024

Hello @c2thorn I updated the PR with the lint fixes. I saw that the test I am adding is passing but I do not know why other tests are failing. is these something related to newest changes in the repo?

These are just already failing tests that my team needs to address at some point. Shouldn't impede this

@modular-magician modular-magician removed the awaiting-approval Pull requests that needs reviewer's approval to run presubmit tests label May 30, 2024
@modular-magician
Copy link
Collaborator

Hi there, I'm the Modular magician. I've detected the following information about your changes:

Diff report

Your PR generated some diffs in downstreams - here they are.

google provider: Diff ( 4 files changed, 187 insertions(+))
google-beta provider: Diff ( 4 files changed, 187 insertions(+))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 941
Passed tests: 833
Skipped tests: 72
Affected tests: 36

Click here to see the affected service packages
  • compute

Action taken

Found 36 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
TestAccComputeAutoscaler_autoscalerBasicExample|TestAccComputeAutoscaler_autoscalerSingleInstanceExample|TestAccComputeAutoscaler_multicondition|TestAccComputeAutoscaler_scaleDownControl|TestAccComputeAutoscaler_scaleInControl|TestAccComputeAutoscaler_scaleInControlFixed|TestAccComputeAutoscaler_scalingSchedule|TestAccComputeAutoscaler_update|TestAccComputeBackendService_withBackendAndIAP|TestAccComputeInstanceNetworkIntefaceWithSecurityPolicy|TestAccComputeInstance_guestAccelerator|TestAccComputePerInstanceConfig_removeInstanceOnDestroy|TestAccComputePerInstanceConfig_statefulIps|TestAccComputePerInstanceConfig_update|TestAccComputeRegionAutoscaler_regionAutoscalerBasicExample|TestAccComputeRegionAutoscaler_scaleDownControl|TestAccComputeRegionAutoscaler_scaleInControl|TestAccComputeRegionAutoscaler_scalingSchedule|TestAccComputeRegionAutoscaler_update|TestAccInstanceGroupManager_autoHealingPolicies|TestAccInstanceGroupManager_basic|TestAccInstanceGroupManager_resourceManagerTags|TestAccInstanceGroupManager_self_link_unique|TestAccInstanceGroupManager_stateful|TestAccInstanceGroupManager_targetSizeZero|TestAccInstanceGroupManager_update|TestAccInstanceGroupManager_versions|TestAccInstanceGroupManager_waitForStatus|TestAccRegionInstanceGroupManager_autoHealingPolicies|TestAccRegionInstanceGroupManager_basic|TestAccRegionInstanceGroupManager_distributionPolicy|TestAccRegionInstanceGroupManager_resourceManagerTags|TestAccRegionInstanceGroupManager_stateful|TestAccRegionInstanceGroupManager_targetSizeZero|TestAccRegionInstanceGroupManager_update|TestAccRegionInstanceGroupManager_versions

Get to know how VCR tests work

@modular-magician
Copy link
Collaborator

$\textcolor{green}{\textsf{Tests passed during RECORDING mode:}}$
TestAccComputeAutoscaler_update[Debug log]
TestAccComputeBackendService_withBackendAndIAP[Debug log]
TestAccComputePerInstanceConfig_removeInstanceOnDestroy[Debug log]
TestAccComputeRegionAutoscaler_regionAutoscalerBasicExample[Debug log]
TestAccComputeRegionAutoscaler_scaleDownControl[Debug log]
TestAccComputeRegionAutoscaler_scaleInControl[Debug log]
TestAccComputeRegionAutoscaler_scalingSchedule[Debug log]
TestAccComputeRegionAutoscaler_update[Debug log]
TestAccRegionInstanceGroupManager_autoHealingPolicies[Debug log]
TestAccRegionInstanceGroupManager_basic[Debug log]
TestAccRegionInstanceGroupManager_distributionPolicy[Debug log]
TestAccRegionInstanceGroupManager_resourceManagerTags[Debug log]
TestAccRegionInstanceGroupManager_stateful[Debug log]
TestAccRegionInstanceGroupManager_targetSizeZero[Debug log]
TestAccRegionInstanceGroupManager_update[Debug log]
TestAccRegionInstanceGroupManager_versions[Debug log]

$\textcolor{green}{\textsf{No issues found for passed tests after REPLAYING rerun.}}$


$\textcolor{red}{\textsf{Tests failed during RECORDING mode:}}$
TestAccComputeAutoscaler_autoscalerBasicExample[Error message] [Debug log]
TestAccComputeAutoscaler_autoscalerSingleInstanceExample[Error message] [Debug log]
TestAccComputeAutoscaler_multicondition[Error message] [Debug log]
TestAccComputeAutoscaler_scaleDownControl[Error message] [Debug log]
TestAccComputeAutoscaler_scaleInControl[Error message] [Debug log]
TestAccComputeAutoscaler_scaleInControlFixed[Error message] [Debug log]
TestAccComputeAutoscaler_scalingSchedule[Error message] [Debug log]
TestAccComputeInstanceNetworkIntefaceWithSecurityPolicy[Error message] [Debug log]
TestAccComputeInstance_guestAccelerator[Error message] [Debug log]
TestAccComputePerInstanceConfig_statefulIps[Error message] [Debug log]
TestAccComputePerInstanceConfig_update[Error message] [Debug log]
TestAccInstanceGroupManager_autoHealingPolicies[Error message] [Debug log]
TestAccInstanceGroupManager_basic[Error message] [Debug log]
TestAccInstanceGroupManager_resourceManagerTags[Error message] [Debug log]
TestAccInstanceGroupManager_self_link_unique[Error message] [Debug log]
TestAccInstanceGroupManager_stateful[Error message] [Debug log]
TestAccInstanceGroupManager_targetSizeZero[Error message] [Debug log]
TestAccInstanceGroupManager_update[Error message] [Debug log]
TestAccInstanceGroupManager_versions[Error message] [Debug log]
TestAccInstanceGroupManager_waitForStatus[Error message] [Debug log]

$\textcolor{red}{\textsf{Please fix these to complete your PR.}}$
View the build log or the debug log for each test

@c2thorn
Copy link
Member

c2thorn commented May 30, 2024

hit a quota issue, should be resolved now.
Rerunning

@c2thorn
Copy link
Member

c2thorn commented May 30, 2024

/gcbrun

@modular-magician modular-magician added awaiting-approval Pull requests that needs reviewer's approval to run presubmit tests and removed awaiting-approval Pull requests that needs reviewer's approval to run presubmit tests labels May 30, 2024
@modular-magician
Copy link
Collaborator

Hi there, I'm the Modular magician. I've detected the following information about your changes:

Diff report

Your PR generated some diffs in downstreams - here they are.

google provider: Diff ( 4 files changed, 187 insertions(+))
google-beta provider: Diff ( 4 files changed, 187 insertions(+))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 941
Passed tests: 849
Skipped tests: 72
Affected tests: 20

Click here to see the affected service packages
  • compute

Action taken

Found 20 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
TestAccComputeAutoscaler_autoscalerBasicExample|TestAccComputeAutoscaler_autoscalerSingleInstanceExample|TestAccComputeAutoscaler_multicondition|TestAccComputeAutoscaler_scaleDownControl|TestAccComputeAutoscaler_scaleInControl|TestAccComputeAutoscaler_scaleInControlFixed|TestAccComputeAutoscaler_scalingSchedule|TestAccComputeInstanceNetworkIntefaceWithSecurityPolicy|TestAccComputeInstance_guestAccelerator|TestAccComputePerInstanceConfig_statefulIps|TestAccComputePerInstanceConfig_update|TestAccInstanceGroupManager_autoHealingPolicies|TestAccInstanceGroupManager_basic|TestAccInstanceGroupManager_resourceManagerTags|TestAccInstanceGroupManager_self_link_unique|TestAccInstanceGroupManager_stateful|TestAccInstanceGroupManager_targetSizeZero|TestAccInstanceGroupManager_update|TestAccInstanceGroupManager_versions|TestAccInstanceGroupManager_waitForStatus

Get to know how VCR tests work

@modular-magician
Copy link
Collaborator

$\textcolor{green}{\textsf{Tests passed during RECORDING mode:}}$
TestAccComputeAutoscaler_multicondition[Debug log]
TestAccComputePerInstanceConfig_statefulIps[Debug log]
TestAccComputePerInstanceConfig_update[Debug log]
TestAccInstanceGroupManager_resourceManagerTags[Debug log]
TestAccInstanceGroupManager_stateful[Debug log]
TestAccInstanceGroupManager_targetSizeZero[Debug log]
TestAccInstanceGroupManager_versions[Debug log]

$\textcolor{green}{\textsf{No issues found for passed tests after REPLAYING rerun.}}$


$\textcolor{red}{\textsf{Tests failed during RECORDING mode:}}$
TestAccComputeAutoscaler_autoscalerBasicExample[Error message] [Debug log]
TestAccComputeAutoscaler_autoscalerSingleInstanceExample[Error message] [Debug log]
TestAccComputeAutoscaler_scaleDownControl[Error message] [Debug log]
TestAccComputeAutoscaler_scaleInControl[Error message] [Debug log]
TestAccComputeAutoscaler_scaleInControlFixed[Error message] [Debug log]
TestAccComputeAutoscaler_scalingSchedule[Error message] [Debug log]
TestAccComputeInstanceNetworkIntefaceWithSecurityPolicy[Error message] [Debug log]
TestAccComputeInstance_guestAccelerator[Error message] [Debug log]
TestAccInstanceGroupManager_autoHealingPolicies[Error message] [Debug log]
TestAccInstanceGroupManager_basic[Error message] [Debug log]
TestAccInstanceGroupManager_self_link_unique[Error message] [Debug log]
TestAccInstanceGroupManager_update[Error message] [Debug log]
TestAccInstanceGroupManager_waitForStatus[Error message] [Debug log]

$\textcolor{red}{\textsf{Please fix these to complete your PR.}}$
View the build log or the debug log for each test

@c2thorn
Copy link
Member

c2thorn commented May 30, 2024

Just been informed we have an issue with our sweepers in the CI project, which means we are hitting many quota limits every test run. Will rerun once it seems resolved

@c2thorn
Copy link
Member

c2thorn commented May 30, 2024

/gcbrun

@modular-magician modular-magician added the awaiting-approval Pull requests that needs reviewer's approval to run presubmit tests label May 30, 2024
Copy link

This PR has been waiting for review for 2 weekdays. Please take a look! Use the label disable-review-reminders to disable these notifications.

2 similar comments
Copy link

github-actions bot commented Jun 1, 2024

This PR has been waiting for review for 2 weekdays. Please take a look! Use the label disable-review-reminders to disable these notifications.

Copy link

github-actions bot commented Jun 2, 2024

This PR has been waiting for review for 2 weekdays. Please take a look! Use the label disable-review-reminders to disable these notifications.

@c2thorn
Copy link
Member

c2thorn commented Jun 3, 2024

Apologies for the delay again, just notifying that I still am aware of this. Should get this merged before the next cutoff.

@modular-magician modular-magician removed the awaiting-approval Pull requests that needs reviewer's approval to run presubmit tests label Jun 3, 2024
@modular-magician
Copy link
Collaborator

Hi there, I'm the Modular magician. I've detected the following information about your changes:

Diff report

Your PR generated some diffs in downstreams - here they are.

google provider: Diff ( 4 files changed, 187 insertions(+))
google-beta provider: Diff ( 4 files changed, 187 insertions(+))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 941
Passed tests: 855
Skipped tests: 72
Affected tests: 14

Click here to see the affected service packages
  • compute

Action taken

Found 14 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
TestAccComputeAutoscaler_autoscalerBasicExample|TestAccComputeAutoscaler_autoscalerSingleInstanceExample|TestAccComputeAutoscaler_scaleDownControl|TestAccComputeAutoscaler_scaleInControl|TestAccComputeAutoscaler_scaleInControlFixed|TestAccComputeAutoscaler_scalingSchedule|TestAccComputeInstanceNetworkIntefaceWithSecurityPolicy|TestAccComputeInstance_guestAccelerator|TestAccComputeRegionPerInstanceConfig_removeInstanceOnDestroy|TestAccInstanceGroupManager_autoHealingPolicies|TestAccInstanceGroupManager_basic|TestAccInstanceGroupManager_self_link_unique|TestAccInstanceGroupManager_update|TestAccInstanceGroupManager_waitForStatus

Get to know how VCR tests work

@modular-magician
Copy link
Collaborator

$\textcolor{green}{\textsf{Tests passed during RECORDING mode:}}$
TestAccComputeRegionPerInstanceConfig_removeInstanceOnDestroy[Debug log]

$\textcolor{green}{\textsf{No issues found for passed tests after REPLAYING rerun.}}$


$\textcolor{red}{\textsf{Tests failed during RECORDING mode:}}$
TestAccComputeAutoscaler_autoscalerBasicExample[Error message] [Debug log]
TestAccComputeAutoscaler_autoscalerSingleInstanceExample[Error message] [Debug log]
TestAccComputeAutoscaler_scaleDownControl[Error message] [Debug log]
TestAccComputeAutoscaler_scaleInControl[Error message] [Debug log]
TestAccComputeAutoscaler_scaleInControlFixed[Error message] [Debug log]
TestAccComputeAutoscaler_scalingSchedule[Error message] [Debug log]
TestAccComputeInstanceNetworkIntefaceWithSecurityPolicy[Error message] [Debug log]
TestAccComputeInstance_guestAccelerator[Error message] [Debug log]
TestAccInstanceGroupManager_autoHealingPolicies[Error message] [Debug log]
TestAccInstanceGroupManager_basic[Error message] [Debug log]
TestAccInstanceGroupManager_self_link_unique[Error message] [Debug log]
TestAccInstanceGroupManager_update[Error message] [Debug log]
TestAccInstanceGroupManager_waitForStatus[Error message] [Debug log]

$\textcolor{red}{\textsf{Please fix these to complete your PR.}}$
View the build log or the debug log for each test

@maxi-cit
Copy link
Contributor Author

maxi-cit commented Jun 4, 2024

Hello @c2thorn, thanks for the response. It looks like there are still some issues with the tests. do you have an estimate on when this will be solved?

@c2thorn
Copy link
Member

c2thorn commented Jun 4, 2024

should be resolved with #10871, but safe to merge now

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

add google_compute_security_policy data source
3 participants