# ----------------------------------------------------------------------------
#
#     ***     AUTO GENERATED CODE    ***    Type: MMv1     ***
#
# ----------------------------------------------------------------------------
#
#     This file is automatically generated by Magic Modules and manual
#     changes will be clobbered when the file is regenerated.
#
#     Please read more about how to change this file in README.md and
#     CONTRIBUTING.md located at the root of this package.
#
# ----------------------------------------------------------------------------

title 'Test GCP google_compute_network_attachment resource.'

gcp_project_id = input(:gcp_project_id, value: 'gcp_project_id', description: 'The GCP project identifier.')

  network_attachment = input('network_attachment', value: {
  "network_attachment": "inspec-test",
  "project": "ppradhan",
  "region": "us-central1",
  "kind": "value_kind",
  "id": "value_id",
  "creation_timestamp": "value_creationtimestamp",
  "name": "inspec-test",
  "description": "value_description",
  "self_link": "value_selflink",
  "self_link_with_id": "value_selflinkwithid",
  "connection_preference": "value_connectionpreference",
  "fingerprint": "value_fingerprint",
  "network": "inspec-network"
}, description: 'network_attachment description')
control 'google_compute_network_attachment-1.0' do
  impact 1.0
  title 'google_compute_network_attachment resource test'

  describe google_compute_network_attachment(network_attachment: network_attachment['network_attachment'], project: gcp_project_id, region: network_attachment['region']) do
  	it { should exist }
  	its('kind') { should cmp network_attachment['kind'] }
  	its('id') { should cmp network_attachment['id'] }
  	its('creation_timestamp') { should cmp network_attachment['creation_timestamp'] }
  	its('name') { should cmp network_attachment['name'] }
  	its('description') { should cmp network_attachment['description'] }
  	its('self_link') { should cmp network_attachment['self_link'] }
  	its('self_link_with_id') { should cmp network_attachment['self_link_with_id'] }
  	its('region') { should cmp network_attachment['region'] }
  	its('connection_preference') { should cmp network_attachment['connection_preference'] }
  	its('fingerprint') { should cmp network_attachment['fingerprint'] }
  	its('network') { should cmp network_attachment['network'] }

  end

  describe google_compute_v1_network_attachment(name: network_attachment['network_attachment'], project: gcp_project_id, region: network_attachment['region']) do
  	it { should_not exist }
  end
end
