A google_cloud_scheduler_jobs is used to test a Google Job resource
google_cloud_scheduler_jobs(project: 'chef-gcp-inspec', region: ).names.each do |name|
describe google_cloud_scheduler_job(project: 'chef-gcp-inspec', region: us-central1, name: name) do
it { should exist }
its('description') { should cmp 'A description' }
its('schedule') { should cmp '*/8 * * * *' }
its('time_zone') { should cmp 'America/New_York' }
its('http_target.http_method') { should cmp 'POST' }
its('http_target.uri') { should cmp 'https://example.com/ping' }
end
end
Properties that can be accessed from the google_cloud_scheduler_jobs resource:
See the google_cloud_scheduler_job resource for more information.
namesgoogle_cloud_scheduler_job namedescriptionsgoogle_cloud_scheduler_job descriptionschedulesgoogle_cloud_scheduler_job scheduletime_zonesgoogle_cloud_scheduler_job time_zoneattempt_deadlinesgoogle_cloud_scheduler_job attempt_deadlineretry_configsgoogle_cloud_scheduler_job retry_configpubsub_targetsgoogle_cloud_scheduler_job pubsub_targetapp_engine_http_targetsgoogle_cloud_scheduler_job app_engine_http_targethttp_targetsgoogle_cloud_scheduler_job http_targetregionsgoogle_cloud_scheduler_job regionThis resource supports all of the above properties as filter criteria, which can be used with where as a block or a method.
© 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_cloud_scheduler_jobs/