A google_resourcemanager_organization_policy is used to test organization policy constraints. More information can be found here Organization Policy Constraints
describe google_resourcemanager_organization_policy(organization_name: "organizations/123456789", constraint: "constraints/compute.disableSerialPortAccess") do
it { should exist }
its('constraint') { should eq 'constraints/compute.disableSerialPortAccess' }
its('boolean_policy.enforced') { should be true }
end
Properties that can be accessed from the google_resourcemanager_organization_policy resource:
versionconstraintupdate_timelist_policyallowed_valuesdenied_valuesboolean_policyenforcedEnsure the Cloud Resource Manager API is enabled for the current project.
© Chef Software, Inc.
Licensed under the Creative Commons Attribution 3.0 Unported License.
The Chef™ Mark and Chef Logo are either registered trademarks/service marks or trademarks/servicemarks of Chef, in the United States and other countries and are used with Chef Inc's permission.
We are not affiliated with, endorsed or sponsored by Chef Inc.
https://docs.chef.io/inspec/resources/google_resourcemanager_organization_policy/