awspec 0.22.1 → 0.23.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +2 -0
- data/doc/_resource_types/autoscaling_group.md +23 -0
- data/doc/_resource_types/cloudwatch_alarm.md +39 -0
- data/doc/_resource_types/directconnect_virtual_interface.md +30 -0
- data/doc/_resource_types/ebs.md +23 -0
- data/doc/_resource_types/ec2.md +61 -1
- data/doc/_resource_types/elasticache.md +47 -0
- data/doc/_resource_types/elasticache_cache_parameter_group.md +8 -0
- data/doc/_resource_types/elb.md +40 -0
- data/doc/_resource_types/iam_group.md +24 -0
- data/doc/_resource_types/iam_policy.md +39 -0
- data/doc/_resource_types/iam_role.md +16 -0
- data/doc/_resource_types/iam_user.md +24 -0
- data/doc/_resource_types/lambda.md +8 -0
- data/doc/_resource_types/network_acl.md +23 -2
- data/doc/_resource_types/rds.md +66 -0
- data/doc/_resource_types/rds_db_parameter_group.md +7 -0
- data/doc/_resource_types/route53_hosted_zone.md +25 -0
- data/doc/_resource_types/route_table.md +16 -0
- data/doc/_resource_types/s3.md +27 -0
- data/doc/_resource_types/security_group.md +8 -0
- data/doc/_resource_types/ses_identity.md +17 -0
- data/doc/_resource_types/subnet.md +15 -0
- data/doc/_resource_types/vpc.md +33 -0
- data/doc/resource_types.md +519 -72
- data/lib/awspec/generator/doc/type/directconnect_virtual_interface.rb +6 -2
- data/lib/awspec/generator/doc/type/ebs.rb +4 -2
- data/lib/awspec/generator/doc/type/ec2.rb +6 -2
- data/lib/awspec/generator/doc/type/elasticache.rb +7 -2
- data/lib/awspec/generator/doc/type/elb.rb +1 -1
- data/lib/awspec/generator/doc/type/network_acl.rb +4 -1
- data/lib/awspec/generator/doc/type/rds.rb +7 -2
- data/lib/awspec/generator/doc/type/s3.rb +1 -1
- data/lib/awspec/generator/doc/type/subnet.rb +4 -2
- data/lib/awspec/generator/doc/type/vpc.rb +4 -2
- data/lib/awspec/generator/template.rb +9 -4
- data/lib/awspec/helper/finder/s3.rb +6 -0
- data/lib/awspec/stub/iam_group.rb +9 -9
- data/lib/awspec/stub/iam_policy.rb +27 -0
- data/lib/awspec/stub/s3.rb +28 -0
- data/lib/awspec/type/directconnect_virtual_interface.rb +2 -2
- data/lib/awspec/type/ebs.rb +2 -2
- data/lib/awspec/type/ec2.rb +2 -2
- data/lib/awspec/type/elasticache.rb +2 -2
- data/lib/awspec/type/rds.rb +2 -2
- data/lib/awspec/type/s3.rb +19 -0
- data/lib/awspec/type/subnet.rb +2 -2
- data/lib/awspec/type/vpc.rb +2 -2
- data/lib/awspec/version.rb +1 -1
- metadata +14 -2
@@ -1,3 +1,11 @@
|
|
1
|
+
### exist
|
2
|
+
|
3
|
+
```ruby
|
4
|
+
describe lambda('my-lambda-function-name') do
|
5
|
+
it { should exist }
|
6
|
+
end
|
7
|
+
```
|
8
|
+
|
1
9
|
### have_event_source
|
2
10
|
|
3
11
|
This matcher does not support Amazon S3 event sources. ( [See SDK doc](http://docs.aws.amazon.com/sdkforruby/api/Aws/Lambda/Client.html#list_event_source_mappings-instance_method) )
|
@@ -1,10 +1,31 @@
|
|
1
|
-
###
|
1
|
+
### exist
|
2
2
|
|
3
3
|
```ruby
|
4
4
|
describe network_acl('my-network-acl') do
|
5
5
|
it { should exist }
|
6
|
-
|
6
|
+
end
|
7
|
+
```
|
8
|
+
|
9
|
+
### have_subnet
|
10
|
+
|
11
|
+
```ruby
|
12
|
+
describe network_acl('my-network-acl') do
|
7
13
|
it { should have_subnet('my-subnet') }
|
14
|
+
end
|
15
|
+
```
|
16
|
+
|
17
|
+
### belong_to_vpc
|
18
|
+
|
19
|
+
```ruby
|
20
|
+
describe network_acl('my-network-acl') do
|
21
|
+
it { should belong_to_vpc('my-vpc') }
|
22
|
+
end
|
23
|
+
```
|
24
|
+
|
25
|
+
### its(:inbound), its(:outbound), its(:inbound_entries_count), its(:outbound_entries_count)
|
26
|
+
|
27
|
+
```ruby
|
28
|
+
describe network_acl('my-network-acl') do
|
8
29
|
its(:inbound) { should be_allowed(80).protocol('tcp').source('123.0.456.789/32') }
|
9
30
|
its(:inbound) { should be_denied.rule_number('*').source('0.0.0.0/0') }
|
10
31
|
its(:outbound) { should be_allowed.protocol('ALL').source('0.0.0.0/0') }
|
@@ -0,0 +1,66 @@
|
|
1
|
+
### exist
|
2
|
+
|
3
|
+
```ruby
|
4
|
+
describe rds('my-rds') do
|
5
|
+
it { should exist }
|
6
|
+
end
|
7
|
+
```
|
8
|
+
|
9
|
+
### be_available, be_backing_up, be_creating, be_deleting, be_failed, be_inaccessible_encryption_credentials, be_incompatible_credentials, be_incompatible_network, be_incompatible_option_group, be_incompatible_parameters, be_incompatible_restore, be_maintenance, be_modifying, be_rebooting, be_renaming, be_resetting_master_credentials, be_restore_error, be_storage_full, be_upgrading
|
10
|
+
|
11
|
+
```ruby
|
12
|
+
describe rds('my-rds') do
|
13
|
+
it { should be_available }
|
14
|
+
end
|
15
|
+
```
|
16
|
+
|
17
|
+
### have_db_parameter_group
|
18
|
+
|
19
|
+
```ruby
|
20
|
+
describe rds('my-rds') do
|
21
|
+
it { should belong_to_db_subnet_group('my-db-subnet-group') }
|
22
|
+
end
|
23
|
+
```
|
24
|
+
|
25
|
+
### have_option_group
|
26
|
+
|
27
|
+
```ruby
|
28
|
+
describe rds('my-rds') do
|
29
|
+
it { should have_option_group('default:mysql-5-6') }
|
30
|
+
end
|
31
|
+
```
|
32
|
+
|
33
|
+
### have_security_group
|
34
|
+
|
35
|
+
```ruby
|
36
|
+
describe rds('my-rds') do
|
37
|
+
it { should have_security_group('sg-5a6b7cd8') }
|
38
|
+
it { should have_security_group('my-db-sg') }
|
39
|
+
end
|
40
|
+
```
|
41
|
+
|
42
|
+
### belong_to_db_subnet_group
|
43
|
+
|
44
|
+
```ruby
|
45
|
+
describe rds('my-rds') do
|
46
|
+
it { should belong_to_db_subnet_group('my-db-subnet-group') }
|
47
|
+
end
|
48
|
+
```
|
49
|
+
|
50
|
+
### belong_to_subnet
|
51
|
+
|
52
|
+
```ruby
|
53
|
+
describe rds('my-rds') do
|
54
|
+
it { should belong_to_subnet('subnet-8901b123') }
|
55
|
+
it { should belong_to_subnet('db-subnet-a') }
|
56
|
+
end
|
57
|
+
```
|
58
|
+
|
59
|
+
### belong_to_vpc
|
60
|
+
|
61
|
+
```ruby
|
62
|
+
describe rds('my-rds') do
|
63
|
+
it { should belong_to_vpc('vpc-ab123cde') }
|
64
|
+
it { should belong_to_vpc('my-vpc') }
|
65
|
+
end
|
66
|
+
```
|
@@ -6,3 +6,10 @@ describe rds_db_parameter_group('my-rds-db-parameter-group') do
|
|
6
6
|
its(:innodb_buffer_pool_size) { '{DBInstanceClassMemory*3/4}' }
|
7
7
|
end
|
8
8
|
```
|
9
|
+
### exist
|
10
|
+
|
11
|
+
```ruby
|
12
|
+
describe rds_db_parameter_group('my-rds-db-parameter-group') do
|
13
|
+
it { should exist }
|
14
|
+
end
|
15
|
+
```
|
@@ -0,0 +1,25 @@
|
|
1
|
+
### exist
|
2
|
+
|
3
|
+
```ruby
|
4
|
+
describe route53_hosted_zone('example.com.') do
|
5
|
+
it { should exist }
|
6
|
+
end
|
7
|
+
```
|
8
|
+
|
9
|
+
### have_record_set
|
10
|
+
|
11
|
+
```ruby
|
12
|
+
describe route53_hosted_zone('example.com.') do
|
13
|
+
its(:resource_record_set_count) { should eq 6 }
|
14
|
+
it { should have_record_set('example.com.').a('123.456.7.890') }
|
15
|
+
it { should have_record_set('*.example.com.').cname('example.com') }
|
16
|
+
it { should have_record_set('example.com.').mx('10 mail.example.com') }
|
17
|
+
it { should have_record_set('mail.example.com.').a('123.456.7.890').ttl(3600) }
|
18
|
+
ns = 'ns-123.awsdns-45.net.
|
19
|
+
ns-6789.awsdns-01.org.
|
20
|
+
ns-2345.awsdns-67.co.uk.
|
21
|
+
ns-890.awsdns-12.com.'
|
22
|
+
it { should have_record_set('example.com.').ns(ns) }
|
23
|
+
it { should have_record_set('s3.example.com.').alias('s3-website-us-east-1.amazonaws.com.', 'Z2ABCDEFGHIJKL') }
|
24
|
+
end
|
25
|
+
```
|
@@ -1,3 +1,11 @@
|
|
1
|
+
### exist
|
2
|
+
|
3
|
+
```ruby
|
4
|
+
describe route_table('my-route-table') do
|
5
|
+
it { should exist }
|
6
|
+
end
|
7
|
+
```
|
8
|
+
|
1
9
|
### have_route
|
2
10
|
|
3
11
|
```ruby
|
@@ -8,3 +16,11 @@ describe route_table('my-route-table') do
|
|
8
16
|
it { should have_route('192.168.2.0/24').target(vpc_peering_connection: 'my-pcx') }
|
9
17
|
end
|
10
18
|
```
|
19
|
+
|
20
|
+
### have_subnet
|
21
|
+
|
22
|
+
```ruby
|
23
|
+
describe route_table('my-route-table') do
|
24
|
+
it { should have_subnet('my-subnet') }
|
25
|
+
end
|
26
|
+
```
|
@@ -0,0 +1,27 @@
|
|
1
|
+
### exist
|
2
|
+
|
3
|
+
```ruby
|
4
|
+
describe s3('my-bucket') do
|
5
|
+
it { should exist }
|
6
|
+
end
|
7
|
+
```
|
8
|
+
|
9
|
+
### have_acl_grant
|
10
|
+
|
11
|
+
```ruby
|
12
|
+
describe s3('my-bucket') do
|
13
|
+
its(:acl_grants_count) { should eq 3 }
|
14
|
+
it { should have_acl_grant(grantee: 'my-bucket-owner', permission: 'FULL_CONTROL') }
|
15
|
+
it { should have_acl_grant(grantee: 'my-bucket-write-only', permission: 'WRITE') }
|
16
|
+
it { should have_acl_grant(grantee: 'my-bucket-read-only', permission: 'READ') }
|
17
|
+
its(:acl_owner) { should eq 'my-bucket-owner' }
|
18
|
+
end
|
19
|
+
```
|
20
|
+
|
21
|
+
### have_object
|
22
|
+
|
23
|
+
```ruby
|
24
|
+
describe s3('my-bucket') do
|
25
|
+
it { should have_object('path/to/object') }
|
26
|
+
end
|
27
|
+
```
|
@@ -0,0 +1,17 @@
|
|
1
|
+
### exist
|
2
|
+
|
3
|
+
```ruby
|
4
|
+
describe ses_identity('example.com') do
|
5
|
+
it { should exist }
|
6
|
+
end
|
7
|
+
```
|
8
|
+
|
9
|
+
### have_dkim_tokens
|
10
|
+
|
11
|
+
### have_identity_policy
|
12
|
+
|
13
|
+
```ruby
|
14
|
+
describe ses_identity('example.com') do
|
15
|
+
it { should have_identity_policy('my-identity-policy-name') }
|
16
|
+
end
|
17
|
+
```
|
@@ -0,0 +1,33 @@
|
|
1
|
+
### exist
|
2
|
+
|
3
|
+
```ruby
|
4
|
+
describe vpc('my-vpc') do
|
5
|
+
it { should exist }
|
6
|
+
end
|
7
|
+
```
|
8
|
+
|
9
|
+
### be_available, be_pending
|
10
|
+
|
11
|
+
```ruby
|
12
|
+
describe vpc('vpc-ab123cde') do
|
13
|
+
it { should be_available }
|
14
|
+
end
|
15
|
+
```
|
16
|
+
|
17
|
+
### have_network_acl
|
18
|
+
|
19
|
+
```ruby
|
20
|
+
describe vpc('vpc-ab123cde') do
|
21
|
+
it { should have_network_acl('acl-1abc2d3e') }
|
22
|
+
it { should have_network_acl('my-network-acl') }
|
23
|
+
end
|
24
|
+
```
|
25
|
+
|
26
|
+
### have_route_table
|
27
|
+
|
28
|
+
```ruby
|
29
|
+
describe vpc('vpc-ab123cde') do
|
30
|
+
it { should have_network_acl('acl-1abc2d3e') }
|
31
|
+
it { should have_network_acl('my-network-acl') }
|
32
|
+
end
|
33
|
+
```
|
data/doc/resource_types.md
CHANGED
@@ -39,9 +39,14 @@ end
|
|
39
39
|
|
40
40
|
### be_disabled_api_termination
|
41
41
|
|
42
|
-
|
42
|
+
```ruby
|
43
|
+
describe ec2('my-ec2') do
|
44
|
+
it { should be_disabled_api_termination }
|
45
|
+
end
|
46
|
+
```
|
43
47
|
|
44
|
-
|
48
|
+
|
49
|
+
### be_pending, be_running, be_shutting_down, be_terminated, be_stopping, be_stopped
|
45
50
|
|
46
51
|
```ruby
|
47
52
|
describe ec2('my-ec2') do
|
@@ -49,24 +54,55 @@ describe ec2('my-ec2') do
|
|
49
54
|
end
|
50
55
|
```
|
51
56
|
|
52
|
-
### be_shutting_down
|
53
|
-
|
54
|
-
### be_stopped
|
55
57
|
|
56
|
-
###
|
58
|
+
### have_ebs
|
57
59
|
|
58
|
-
|
60
|
+
```ruby
|
61
|
+
describe ec2('my-ec2') do
|
62
|
+
it { should have_ebs('vol-123a123b') }
|
63
|
+
it { should have_ebs('my-volume') }
|
64
|
+
end
|
65
|
+
```
|
59
66
|
|
60
|
-
### have_ebs
|
61
67
|
|
62
68
|
### have_eip
|
63
69
|
|
70
|
+
```ruby
|
71
|
+
describe ec2('my-ec2') do
|
72
|
+
it { should have_eip('123.0.456.789') }
|
73
|
+
end
|
74
|
+
```
|
75
|
+
|
76
|
+
|
64
77
|
### have_security_group
|
65
78
|
|
79
|
+
```ruby
|
80
|
+
describe ec2('my-ec2') do
|
81
|
+
it { should have_security_group('my-security-group-name') }
|
82
|
+
it { should have_security_group('sg-1a2b3cd4') }
|
83
|
+
end
|
84
|
+
```
|
85
|
+
|
86
|
+
|
66
87
|
### belong_to_subnet
|
67
88
|
|
89
|
+
```ruby
|
90
|
+
describe ec2('my-ec2') do
|
91
|
+
it { should belong_to_subnet('subnet-1234a567') }
|
92
|
+
it { should belong_to_subnet('my-subnet') }
|
93
|
+
end
|
94
|
+
```
|
95
|
+
|
96
|
+
|
68
97
|
### belong_to_vpc
|
69
98
|
|
99
|
+
```ruby
|
100
|
+
describe ec2('my-ec2') do
|
101
|
+
it { should belong_to_vpc('vpc-ab123cde') }
|
102
|
+
it { should belong_to_vpc('my-vpc') }
|
103
|
+
end
|
104
|
+
```
|
105
|
+
|
70
106
|
#### its(:instance_id), its(:image_id), its(:private_dns_name), its(:public_dns_name), its(:state_transition_reason), its(:key_name), its(:ami_launch_index), its(:instance_type), its(:launch_time), its(:placement), its(:kernel_id), its(:ramdisk_id), its(:platform), its(:monitoring), its(:subnet_id), its(:vpc_id), its(:private_ip_address), its(:public_ip_address), its(:state_reason), its(:architecture), its(:root_device_type), its(:root_device_name), its(:virtualization_type), its(:instance_lifecycle), its(:spot_instance_request_id), its(:client_token), its(:source_dest_check), its(:hypervisor), its(:iam_instance_profile), its(:ebs_optimized), its(:sriov_net_support)
|
71
107
|
## <a name="rds">rds</a>
|
72
108
|
|
@@ -74,56 +110,78 @@ RDS resource type.
|
|
74
110
|
|
75
111
|
### exist
|
76
112
|
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
### be_deleting
|
84
|
-
|
85
|
-
### be_failed
|
113
|
+
```ruby
|
114
|
+
describe rds('my-rds') do
|
115
|
+
it { should exist }
|
116
|
+
end
|
117
|
+
```
|
86
118
|
|
87
|
-
### be_inaccessible_encryption_credentials
|
88
119
|
|
89
|
-
### be_incompatible_credentials
|
120
|
+
### be_available, be_backing_up, be_creating, be_deleting, be_failed, be_inaccessible_encryption_credentials, be_incompatible_credentials, be_incompatible_network, be_incompatible_option_group, be_incompatible_parameters, be_incompatible_restore, be_maintenance, be_modifying, be_rebooting, be_renaming, be_resetting_master_credentials, be_restore_error, be_storage_full, be_upgrading
|
90
121
|
|
91
|
-
|
122
|
+
```ruby
|
123
|
+
describe rds('my-rds') do
|
124
|
+
it { should be_available }
|
125
|
+
end
|
126
|
+
```
|
92
127
|
|
93
|
-
### be_incompatible_option_group
|
94
128
|
|
95
|
-
###
|
129
|
+
### have_db_parameter_group
|
96
130
|
|
97
|
-
|
131
|
+
```ruby
|
132
|
+
describe rds('my-rds') do
|
133
|
+
it { should belong_to_db_subnet_group('my-db-subnet-group') }
|
134
|
+
end
|
135
|
+
```
|
98
136
|
|
99
|
-
### be_maintenance
|
100
137
|
|
101
|
-
###
|
138
|
+
### have_option_group
|
102
139
|
|
103
|
-
|
140
|
+
```ruby
|
141
|
+
describe rds('my-rds') do
|
142
|
+
it { should have_option_group('default:mysql-5-6') }
|
143
|
+
end
|
144
|
+
```
|
104
145
|
|
105
|
-
### be_renaming
|
106
146
|
|
107
|
-
###
|
147
|
+
### have_security_group
|
108
148
|
|
109
|
-
|
149
|
+
```ruby
|
150
|
+
describe rds('my-rds') do
|
151
|
+
it { should have_security_group('sg-5a6b7cd8') }
|
152
|
+
it { should have_security_group('my-db-sg') }
|
153
|
+
end
|
154
|
+
```
|
110
155
|
|
111
|
-
### be_storage_full
|
112
156
|
|
113
|
-
###
|
157
|
+
### belong_to_db_subnet_group
|
114
158
|
|
115
|
-
|
159
|
+
```ruby
|
160
|
+
describe rds('my-rds') do
|
161
|
+
it { should belong_to_db_subnet_group('my-db-subnet-group') }
|
162
|
+
end
|
163
|
+
```
|
116
164
|
|
117
|
-
### have_option_group
|
118
165
|
|
119
|
-
###
|
166
|
+
### belong_to_subnet
|
120
167
|
|
121
|
-
|
168
|
+
```ruby
|
169
|
+
describe rds('my-rds') do
|
170
|
+
it { should belong_to_subnet('subnet-8901b123') }
|
171
|
+
it { should belong_to_subnet('db-subnet-a') }
|
172
|
+
end
|
173
|
+
```
|
122
174
|
|
123
|
-
### belong_to_subnet
|
124
175
|
|
125
176
|
### belong_to_vpc
|
126
177
|
|
178
|
+
```ruby
|
179
|
+
describe rds('my-rds') do
|
180
|
+
it { should belong_to_vpc('vpc-ab123cde') }
|
181
|
+
it { should belong_to_vpc('my-vpc') }
|
182
|
+
end
|
183
|
+
```
|
184
|
+
|
127
185
|
#### its(:vpc_id), its(:db_instance_identifier), its(:db_instance_class), its(:engine), its(:db_instance_status), its(:master_username), its(:db_name), its(:endpoint), its(:allocated_storage), its(:instance_create_time), its(:preferred_backup_window), its(:backup_retention_period), its(:availability_zone), its(:preferred_maintenance_window), its(:pending_modified_values), its(:latest_restorable_time), its(:multi_az), its(:engine_version), its(:auto_minor_version_upgrade), its(:read_replica_source_db_instance_identifier), its(:license_model), its(:iops), its(:character_set_name), its(:secondary_availability_zone), its(:publicly_accessible), its(:storage_type), its(:tde_credential_arn), its(:db_instance_port), its(:db_cluster_identifier), its(:storage_encrypted), its(:kms_key_id), its(:dbi_resource_id), its(:ca_certificate_identifier), its(:copy_tags_to_snapshot)
|
128
186
|
## <a name="rds_db_parameter_group">rds_db_parameter_group</a>
|
129
187
|
|
@@ -138,6 +196,12 @@ end
|
|
138
196
|
|
139
197
|
### exist
|
140
198
|
|
199
|
+
```ruby
|
200
|
+
describe rds_db_parameter_group('my-rds-db-parameter-group') do
|
201
|
+
it { should exist }
|
202
|
+
end
|
203
|
+
```
|
204
|
+
|
141
205
|
|
142
206
|
## <a name="security_group">security_group</a>
|
143
207
|
|
@@ -145,6 +209,13 @@ SecurityGroup resource type.
|
|
145
209
|
|
146
210
|
### exist
|
147
211
|
|
212
|
+
```ruby
|
213
|
+
describe security_group('my-security-group-name') do
|
214
|
+
it { should exist }
|
215
|
+
end
|
216
|
+
```
|
217
|
+
|
218
|
+
|
148
219
|
### its(:inbound), its(:outbound)
|
149
220
|
|
150
221
|
```ruby
|
@@ -163,14 +234,41 @@ VPC resource type.
|
|
163
234
|
|
164
235
|
### exist
|
165
236
|
|
166
|
-
|
237
|
+
```ruby
|
238
|
+
describe vpc('my-vpc') do
|
239
|
+
it { should exist }
|
240
|
+
end
|
241
|
+
```
|
242
|
+
|
243
|
+
|
244
|
+
### be_available, be_pending
|
245
|
+
|
246
|
+
```ruby
|
247
|
+
describe vpc('vpc-ab123cde') do
|
248
|
+
it { should be_available }
|
249
|
+
end
|
250
|
+
```
|
167
251
|
|
168
|
-
### be_pending
|
169
252
|
|
170
253
|
### have_network_acl
|
171
254
|
|
255
|
+
```ruby
|
256
|
+
describe vpc('vpc-ab123cde') do
|
257
|
+
it { should have_network_acl('acl-1abc2d3e') }
|
258
|
+
it { should have_network_acl('my-network-acl') }
|
259
|
+
end
|
260
|
+
```
|
261
|
+
|
262
|
+
|
172
263
|
### have_route_table
|
173
264
|
|
265
|
+
```ruby
|
266
|
+
describe vpc('vpc-ab123cde') do
|
267
|
+
it { should have_network_acl('acl-1abc2d3e') }
|
268
|
+
it { should have_network_acl('my-network-acl') }
|
269
|
+
end
|
270
|
+
```
|
271
|
+
|
174
272
|
#### its(:vpc_id), its(:state), its(:cidr_block), its(:dhcp_options_id), its(:instance_tenancy), its(:is_default)
|
175
273
|
## <a name="s3">s3</a>
|
176
274
|
|
@@ -178,17 +276,66 @@ S3 resource type.
|
|
178
276
|
|
179
277
|
### exist
|
180
278
|
|
279
|
+
```ruby
|
280
|
+
describe s3('my-bucket') do
|
281
|
+
it { should exist }
|
282
|
+
end
|
283
|
+
```
|
284
|
+
|
285
|
+
|
286
|
+
### have_acl_grant
|
287
|
+
|
288
|
+
```ruby
|
289
|
+
describe s3('my-bucket') do
|
290
|
+
its(:acl_grants_count) { should eq 3 }
|
291
|
+
it { should have_acl_grant(grantee: 'my-bucket-owner', permission: 'FULL_CONTROL') }
|
292
|
+
it { should have_acl_grant(grantee: 'my-bucket-write-only', permission: 'WRITE') }
|
293
|
+
it { should have_acl_grant(grantee: 'my-bucket-read-only', permission: 'READ') }
|
294
|
+
its(:acl_owner) { should eq 'my-bucket-owner' }
|
295
|
+
end
|
296
|
+
```
|
297
|
+
|
298
|
+
|
181
299
|
### have_object
|
182
300
|
|
183
|
-
|
301
|
+
```ruby
|
302
|
+
describe s3('my-bucket') do
|
303
|
+
it { should have_object('path/to/object') }
|
304
|
+
end
|
305
|
+
```
|
306
|
+
|
307
|
+
#### its(:acl_grants_count), its(:acl_owner), its(:name), its(:creation_date)
|
184
308
|
## <a name="route53_hosted_zone">route53_hosted_zone</a>
|
185
309
|
|
186
310
|
Route53HostedZone resource type.
|
187
311
|
|
188
312
|
### exist
|
189
313
|
|
314
|
+
```ruby
|
315
|
+
describe route53_hosted_zone('example.com.') do
|
316
|
+
it { should exist }
|
317
|
+
end
|
318
|
+
```
|
319
|
+
|
320
|
+
|
190
321
|
### have_record_set
|
191
322
|
|
323
|
+
```ruby
|
324
|
+
describe route53_hosted_zone('example.com.') do
|
325
|
+
its(:resource_record_set_count) { should eq 6 }
|
326
|
+
it { should have_record_set('example.com.').a('123.456.7.890') }
|
327
|
+
it { should have_record_set('*.example.com.').cname('example.com') }
|
328
|
+
it { should have_record_set('example.com.').mx('10 mail.example.com') }
|
329
|
+
it { should have_record_set('mail.example.com.').a('123.456.7.890').ttl(3600) }
|
330
|
+
ns = 'ns-123.awsdns-45.net.
|
331
|
+
ns-6789.awsdns-01.org.
|
332
|
+
ns-2345.awsdns-67.co.uk.
|
333
|
+
ns-890.awsdns-12.com.'
|
334
|
+
it { should have_record_set('example.com.').ns(ns) }
|
335
|
+
it { should have_record_set('s3.example.com.').alias('s3-website-us-east-1.amazonaws.com.', 'Z2ABCDEFGHIJKL') }
|
336
|
+
end
|
337
|
+
```
|
338
|
+
|
192
339
|
#### its(:id), its(:name), its(:caller_reference), its(:config), its(:resource_record_set_count)
|
193
340
|
## <a name="autoscaling_group">autoscaling_group</a>
|
194
341
|
|
@@ -196,10 +343,30 @@ AutoscalingGroup resource type.
|
|
196
343
|
|
197
344
|
### exist
|
198
345
|
|
346
|
+
```ruby
|
347
|
+
describe autoscaling_group('my-auto-scaling-group') do
|
348
|
+
it { should exist }
|
349
|
+
end
|
350
|
+
```
|
351
|
+
|
352
|
+
|
199
353
|
### have_ec2
|
200
354
|
|
355
|
+
```ruby
|
356
|
+
describe autoscaling_group('my-auto-scaling-group') do
|
357
|
+
it { should have_ec2('my-ec2') }
|
358
|
+
end
|
359
|
+
```
|
360
|
+
|
361
|
+
|
201
362
|
### have_elb
|
202
363
|
|
364
|
+
```ruby
|
365
|
+
describe autoscaling_group('my-auto-scaling-group') do
|
366
|
+
it { should have_elb('my-elb') }
|
367
|
+
end
|
368
|
+
```
|
369
|
+
|
203
370
|
#### its(:auto_scaling_group_name), its(:auto_scaling_group_arn), its(:launch_configuration_name), its(:min_size), its(:max_size), its(:desired_capacity), its(:default_cooldown), its(:health_check_type), its(:health_check_grace_period), its(:created_time), its(:placement_group), its(:vpc_zone_identifier), its(:status)
|
204
371
|
## <a name="subnet">subnet</a>
|
205
372
|
|
@@ -207,9 +374,20 @@ Subnet resource type.
|
|
207
374
|
|
208
375
|
### exist
|
209
376
|
|
210
|
-
|
377
|
+
```ruby
|
378
|
+
describe subnet('my-subnet') do
|
379
|
+
it { should exist }
|
380
|
+
end
|
381
|
+
```
|
382
|
+
|
211
383
|
|
212
|
-
### be_pending
|
384
|
+
### be_available, be_pending
|
385
|
+
|
386
|
+
```ruby
|
387
|
+
describe subnet('my-subnet') do
|
388
|
+
it { should be_available }
|
389
|
+
end
|
390
|
+
```
|
213
391
|
|
214
392
|
#### its(:subnet_id), its(:state), its(:vpc_id), its(:cidr_block), its(:available_ip_address_count), its(:availability_zone), its(:default_for_az), its(:map_public_ip_on_launch)
|
215
393
|
## <a name="route_table">route_table</a>
|
@@ -218,6 +396,13 @@ RouteTable resource type.
|
|
218
396
|
|
219
397
|
### exist
|
220
398
|
|
399
|
+
```ruby
|
400
|
+
describe route_table('my-route-table') do
|
401
|
+
it { should exist }
|
402
|
+
end
|
403
|
+
```
|
404
|
+
|
405
|
+
|
221
406
|
### have_route
|
222
407
|
|
223
408
|
```ruby
|
@@ -229,8 +414,15 @@ describe route_table('my-route-table') do
|
|
229
414
|
end
|
230
415
|
```
|
231
416
|
|
417
|
+
|
232
418
|
### have_subnet
|
233
419
|
|
420
|
+
```ruby
|
421
|
+
describe route_table('my-route-table') do
|
422
|
+
it { should have_subnet('my-subnet') }
|
423
|
+
end
|
424
|
+
```
|
425
|
+
|
234
426
|
#### its(:route_table_id), its(:vpc_id)
|
235
427
|
## <a name="ebs">ebs</a>
|
236
428
|
|
@@ -238,19 +430,29 @@ EBS resource type.
|
|
238
430
|
|
239
431
|
### exist
|
240
432
|
|
241
|
-
|
433
|
+
```ruby
|
434
|
+
describe ebs('my-volume') do
|
435
|
+
it { should exist }
|
436
|
+
end
|
437
|
+
```
|
242
438
|
|
243
|
-
### be_available
|
244
439
|
|
245
|
-
###
|
440
|
+
### be_attached_to
|
246
441
|
|
247
|
-
|
442
|
+
```ruby
|
443
|
+
describe ebs('my-volume') do
|
444
|
+
it { should be_attached_to('my-ec2') }
|
445
|
+
end
|
446
|
+
```
|
248
447
|
|
249
|
-
### be_deleting
|
250
448
|
|
251
|
-
### be_error
|
449
|
+
### be_creating, be_available, be_in_use, be_deleting, be_deleted, be_error
|
252
450
|
|
253
|
-
|
451
|
+
```ruby
|
452
|
+
describe ebs('my-volume') do
|
453
|
+
it { should be_in_use }
|
454
|
+
end
|
455
|
+
```
|
254
456
|
|
255
457
|
#### its(:volume_id), its(:size), its(:snapshot_id), its(:availability_zone), its(:state), its(:create_time), its(:volume_type), its(:iops), its(:encrypted), its(:kms_key_id)
|
256
458
|
## <a name="elb">elb</a>
|
@@ -259,8 +461,22 @@ ELB resource type.
|
|
259
461
|
|
260
462
|
### exist
|
261
463
|
|
464
|
+
```ruby
|
465
|
+
describe elb('my-elb') do
|
466
|
+
it { should exist }
|
467
|
+
end
|
468
|
+
```
|
469
|
+
|
470
|
+
|
262
471
|
### have_ec2
|
263
472
|
|
473
|
+
```ruby
|
474
|
+
describe elb('my-elb') do
|
475
|
+
it { should have_ec2('my-ec2') }
|
476
|
+
end
|
477
|
+
```
|
478
|
+
|
479
|
+
|
264
480
|
### have_listener
|
265
481
|
|
266
482
|
http://docs.aws.amazon.com/en_us/ElasticLoadBalancing/latest/DeveloperGuide/elb-listener-config.html
|
@@ -271,14 +487,33 @@ describe elb('my-elb') do
|
|
271
487
|
end
|
272
488
|
```
|
273
489
|
|
490
|
+
|
274
491
|
### have_security_group
|
275
492
|
|
493
|
+
```ruby
|
494
|
+
describe elb('my-elb') do
|
495
|
+
it { should have_security_group('my-lb-security-group-tag-name') }
|
496
|
+
end
|
497
|
+
```
|
498
|
+
|
499
|
+
|
276
500
|
### have_subnet
|
277
501
|
|
278
|
-
|
502
|
+
```ruby
|
503
|
+
describe elb('my-elb') do
|
504
|
+
it { should have_subnet('my-subnet') }
|
505
|
+
end
|
506
|
+
```
|
507
|
+
|
279
508
|
|
280
509
|
### belong_to_vpc
|
281
510
|
|
511
|
+
```ruby
|
512
|
+
describe elb('my-elb') do
|
513
|
+
it { should belong_to_vpc('my-vpc') }
|
514
|
+
end
|
515
|
+
```
|
516
|
+
|
282
517
|
#### its(:health_check_target), its(:health_check_interval), its(:health_check_timeout), its(:health_check_unhealthy_threshold), its(:health_check_healthy_threshold), its(:load_balancer_name), its(:dns_name), its(:canonical_hosted_zone_name), its(:canonical_hosted_zone_name_id), its(:vpc_id), its(:created_time), its(:scheme)
|
283
518
|
## <a name="lambda">lambda</a>
|
284
519
|
|
@@ -286,6 +521,13 @@ Lambda resource type.
|
|
286
521
|
|
287
522
|
### exist
|
288
523
|
|
524
|
+
```ruby
|
525
|
+
describe lambda('my-lambda-function-name') do
|
526
|
+
it { should exist }
|
527
|
+
end
|
528
|
+
```
|
529
|
+
|
530
|
+
|
289
531
|
### have_event_source
|
290
532
|
|
291
533
|
This matcher does not support Amazon S3 event sources. ( [See SDK doc](http://docs.aws.amazon.com/sdkforruby/api/Aws/Lambda/Client.html#list_event_source_mappings-instance_method) )
|
@@ -297,6 +539,13 @@ IamUser resource type.
|
|
297
539
|
|
298
540
|
### exist
|
299
541
|
|
542
|
+
```ruby
|
543
|
+
describe iam_user('my-iam-user') do
|
544
|
+
it { should exist }
|
545
|
+
end
|
546
|
+
```
|
547
|
+
|
548
|
+
|
300
549
|
### be_allowed_action
|
301
550
|
|
302
551
|
```ruby
|
@@ -306,10 +555,24 @@ describe iam_user('my-iam-user') do
|
|
306
555
|
end
|
307
556
|
```
|
308
557
|
|
558
|
+
|
309
559
|
### have_iam_policy
|
310
560
|
|
561
|
+
```ruby
|
562
|
+
describe iam_user('my-iam-user') do
|
563
|
+
it { should have_iam_policy('ReadOnlyAccess') }
|
564
|
+
end
|
565
|
+
```
|
566
|
+
|
567
|
+
|
311
568
|
### belong_to_iam_group
|
312
569
|
|
570
|
+
```ruby
|
571
|
+
describe iam_user('my-iam-user') do
|
572
|
+
it { should belong_to_iam_group('my-iam-group') }
|
573
|
+
end
|
574
|
+
```
|
575
|
+
|
313
576
|
#### its(:path), its(:user_name), its(:user_id), its(:arn), its(:create_date), its(:password_last_used)
|
314
577
|
## <a name="iam_group">iam_group</a>
|
315
578
|
|
@@ -317,6 +580,13 @@ IamGroup resource type.
|
|
317
580
|
|
318
581
|
### exist
|
319
582
|
|
583
|
+
```ruby
|
584
|
+
describe iam_group('my-iam-group') do
|
585
|
+
it { should exist }
|
586
|
+
end
|
587
|
+
```
|
588
|
+
|
589
|
+
|
320
590
|
### be_allowed_action
|
321
591
|
|
322
592
|
```ruby
|
@@ -326,10 +596,24 @@ describe iam_group('my-iam-group') do
|
|
326
596
|
end
|
327
597
|
```
|
328
598
|
|
599
|
+
|
329
600
|
### have_iam_policy
|
330
601
|
|
602
|
+
```ruby
|
603
|
+
describe iam_group('my-iam-group') do
|
604
|
+
it { should have_iam_policy('ReadOnlyAccess') }
|
605
|
+
end
|
606
|
+
```
|
607
|
+
|
608
|
+
|
331
609
|
### have_iam_user
|
332
610
|
|
611
|
+
```ruby
|
612
|
+
describe iam_group('my-iam-group') do
|
613
|
+
it { should have_iam_user('my-iam-user') }
|
614
|
+
end
|
615
|
+
```
|
616
|
+
|
333
617
|
#### its(:path), its(:group_name), its(:group_id), its(:arn), its(:create_date)
|
334
618
|
## <a name="iam_role">iam_role</a>
|
335
619
|
|
@@ -337,6 +621,13 @@ IamRole resource type.
|
|
337
621
|
|
338
622
|
### exist
|
339
623
|
|
624
|
+
```ruby
|
625
|
+
describe iam_role('my-iam-role') do
|
626
|
+
it { should exist }
|
627
|
+
end
|
628
|
+
```
|
629
|
+
|
630
|
+
|
340
631
|
### be_allowed_action
|
341
632
|
|
342
633
|
```ruby
|
@@ -346,8 +637,15 @@ describe iam_role('my-iam-role') do
|
|
346
637
|
end
|
347
638
|
```
|
348
639
|
|
640
|
+
|
349
641
|
### have_iam_policy
|
350
642
|
|
643
|
+
```ruby
|
644
|
+
describe iam_role('my-iam-role') do
|
645
|
+
it { should have_iam_policy('ReadOnlyAccess') }
|
646
|
+
end
|
647
|
+
```
|
648
|
+
|
351
649
|
#### its(:path), its(:role_name), its(:role_id), its(:arn), its(:create_date), its(:assume_role_policy_document)
|
352
650
|
## <a name="iam_policy">iam_policy</a>
|
353
651
|
|
@@ -355,14 +653,48 @@ IamPolicy resource type.
|
|
355
653
|
|
356
654
|
### exist
|
357
655
|
|
656
|
+
```ruby
|
657
|
+
describe iam_policy('my-iam-policy') do
|
658
|
+
it { should exist }
|
659
|
+
end
|
660
|
+
```
|
661
|
+
|
662
|
+
|
358
663
|
### be_attachable
|
359
664
|
|
665
|
+
```ruby
|
666
|
+
describe iam_policy('my-iam-policy') do
|
667
|
+
it { should be_attachable }
|
668
|
+
end
|
669
|
+
```
|
670
|
+
|
671
|
+
|
360
672
|
### be_attached_to_group
|
361
673
|
|
674
|
+
```ruby
|
675
|
+
describe iam_policy('my-iam-policy') do
|
676
|
+
it { should be_attached_to_group('my-iam-group') }
|
677
|
+
end
|
678
|
+
```
|
679
|
+
|
680
|
+
|
362
681
|
### be_attached_to_role
|
363
682
|
|
683
|
+
```ruby
|
684
|
+
describe iam_policy('my-iam-policy') do
|
685
|
+
it { should be_attached_to_role('HelloIAmGodRole') }
|
686
|
+
end
|
687
|
+
```
|
688
|
+
|
689
|
+
|
364
690
|
### be_attached_to_user
|
365
691
|
|
692
|
+
```ruby
|
693
|
+
describe iam_policy('my-iam-policy') do
|
694
|
+
it { should be_attached_to_policy('my-iam-policy') }
|
695
|
+
end
|
696
|
+
```
|
697
|
+
|
366
698
|
#### its(:policy_name), its(:policy_id), its(:arn), its(:path), its(:default_version_id), its(:attachment_count), its(:is_attachable), its(:description), its(:create_date), its(:update_date)
|
367
699
|
## <a name="elasticache">elasticache</a>
|
368
700
|
|
@@ -370,32 +702,57 @@ Elasticache resource type.
|
|
370
702
|
|
371
703
|
### exist
|
372
704
|
|
373
|
-
|
705
|
+
```ruby
|
706
|
+
describe elasticache('my-rep-group-001') do
|
707
|
+
it { should exist }
|
708
|
+
end
|
709
|
+
```
|
374
710
|
|
375
|
-
### be_creating
|
376
711
|
|
377
|
-
### be_deleted
|
712
|
+
### be_available, be_creating, be_deleted, be_deleting, be_incompatible_network, be_modifying, be_rebooting_cache_cluster_nodes, be_restore_failed, be_snapshotting
|
378
713
|
|
379
|
-
|
714
|
+
```ruby
|
715
|
+
describe elasticache('my-rep-group-001') do
|
716
|
+
it { should be_available }
|
717
|
+
end
|
718
|
+
```
|
380
719
|
|
381
|
-
### be_incompatible_network
|
382
720
|
|
383
|
-
###
|
721
|
+
### have_cache_parameter_group
|
384
722
|
|
385
|
-
|
723
|
+
```ruby
|
724
|
+
describe elasticache('my-rep-group-001') do
|
725
|
+
it { should have_cache_parameter_group('my-cache-parameter-group') }
|
726
|
+
end
|
727
|
+
```
|
386
728
|
|
387
|
-
### be_restore_failed
|
388
729
|
|
389
|
-
###
|
730
|
+
### belong_to_cache_subnet_group
|
390
731
|
|
391
|
-
|
732
|
+
```ruby
|
733
|
+
describe elasticache('my-rep-group-001') do
|
734
|
+
it { should belong_to_cache_subnet_group('my-cache-subnet-group') }
|
735
|
+
end
|
736
|
+
```
|
392
737
|
|
393
|
-
### belong_to_cache_subnet_group
|
394
738
|
|
395
739
|
### belong_to_replication_group
|
396
740
|
|
741
|
+
```ruby
|
742
|
+
describe elasticache('my-rep-group-001') do
|
743
|
+
it { should belong_to_replication_group('my-rep-group') }
|
744
|
+
end
|
745
|
+
```
|
746
|
+
|
747
|
+
|
397
748
|
### belong_to_vpc
|
398
749
|
|
750
|
+
```ruby
|
751
|
+
describe elasticache('my-rep-group-001') do
|
752
|
+
it { should belong_to_vpc('my-vpc') }
|
753
|
+
end
|
754
|
+
```
|
755
|
+
|
399
756
|
#### its(:cache_cluster_id), its(:configuration_endpoint), its(:client_download_landing_page), its(:cache_node_type), its(:engine), its(:engine_version), its(:cache_cluster_status), its(:num_cache_nodes), its(:preferred_availability_zone), its(:cache_cluster_create_time), its(:preferred_maintenance_window), its(:notification_configuration), its(:cache_subnet_group_name), its(:auto_minor_version_upgrade), its(:replication_group_id), its(:snapshot_retention_limit), its(:snapshot_window)
|
400
757
|
## <a name="elasticache_cache_parameter_group">elasticache_cache_parameter_group</a>
|
401
758
|
|
@@ -409,8 +766,15 @@ describe elasticache_cache_parameter_group('my-cache-parameter-group') do
|
|
409
766
|
end
|
410
767
|
```
|
411
768
|
|
769
|
+
|
412
770
|
### exist
|
413
771
|
|
772
|
+
```ruby
|
773
|
+
describe elasticache_cache_parameter_group('my-cache-parameter-group') do
|
774
|
+
it { should exist }
|
775
|
+
end
|
776
|
+
```
|
777
|
+
|
414
778
|
|
415
779
|
## <a name="cloudwatch_alarm">cloudwatch_alarm</a>
|
416
780
|
|
@@ -418,14 +782,48 @@ CloudwatchAlarm resource type.
|
|
418
782
|
|
419
783
|
### exist
|
420
784
|
|
785
|
+
```ruby
|
786
|
+
describe cloudwatch_alarm('my-cloudwatch-alarm') do
|
787
|
+
it { should exist }
|
788
|
+
end
|
789
|
+
```
|
790
|
+
|
791
|
+
|
421
792
|
### have_alarm_action
|
422
793
|
|
794
|
+
```ruby
|
795
|
+
describe cloudwatch_alarm('my-cloudwatch-alarm') do
|
796
|
+
it { should have_alarm_action('arn:aws:sns:ap-northeast-1:1234567890:sns_alert') }
|
797
|
+
end
|
798
|
+
```
|
799
|
+
|
800
|
+
|
423
801
|
### have_insufficient_data_action
|
424
802
|
|
803
|
+
```ruby
|
804
|
+
describe cloudwatch_alarm('my-cloudwatch-alarm') do
|
805
|
+
it { should have_insufficient_data_action('arn:aws:sns:ap-northeast-1:1234567890:sns_alert') }
|
806
|
+
end
|
807
|
+
```
|
808
|
+
|
809
|
+
|
425
810
|
### have_ok_action
|
426
811
|
|
812
|
+
```ruby
|
813
|
+
describe cloudwatch_alarm('my-cloudwatch-alarm') do
|
814
|
+
it { should have_ok_action('arn:aws:sns:ap-northeast-1:1234567890:sns_alert') }
|
815
|
+
end
|
816
|
+
```
|
817
|
+
|
818
|
+
|
427
819
|
### belong_to_metric
|
428
820
|
|
821
|
+
```ruby
|
822
|
+
describe cloudwatch_alarm('my-cloudwatch-alarm') do
|
823
|
+
it { should belong_to_metric('NumberOfProcesses').namespace('my-cloudwatch-namespace') }
|
824
|
+
end
|
825
|
+
```
|
826
|
+
|
429
827
|
#### its(:alarm_name), its(:alarm_arn), its(:alarm_description), its(:alarm_configuration_updated_timestamp), its(:actions_enabled), its(:state_value), its(:state_reason), its(:state_reason_data), its(:state_updated_timestamp), its(:metric_name), its(:namespace), its(:statistic), its(:period), its(:unit), its(:evaluation_periods), its(:threshold), its(:comparison_operator)
|
430
828
|
## <a name="ses_identity">ses_identity</a>
|
431
829
|
|
@@ -433,10 +831,24 @@ SesIdentity resource type.
|
|
433
831
|
|
434
832
|
### exist
|
435
833
|
|
834
|
+
```ruby
|
835
|
+
describe ses_identity('example.com') do
|
836
|
+
it { should exist }
|
837
|
+
end
|
838
|
+
```
|
839
|
+
|
840
|
+
|
436
841
|
### have_dkim_tokens
|
437
842
|
|
843
|
+
|
438
844
|
### have_identity_policy
|
439
845
|
|
846
|
+
```ruby
|
847
|
+
describe ses_identity('example.com') do
|
848
|
+
it { should have_identity_policy('my-identity-policy-name') }
|
849
|
+
end
|
850
|
+
```
|
851
|
+
|
440
852
|
#### its(:dkim_enabled), its(:dkim_verification_status), its(:bounce_topic), its(:complaint_topic), its(:delivery_topic), its(:forwarding_enabled), its(:verification_status), its(:verification_token)
|
441
853
|
## <a name="network_acl">network_acl</a>
|
442
854
|
|
@@ -444,15 +856,35 @@ NetworkAcl resource type.
|
|
444
856
|
|
445
857
|
### exist
|
446
858
|
|
859
|
+
```ruby
|
860
|
+
describe network_acl('my-network-acl') do
|
861
|
+
it { should exist }
|
862
|
+
end
|
863
|
+
```
|
864
|
+
|
865
|
+
|
447
866
|
### have_subnet
|
448
867
|
|
449
|
-
|
868
|
+
```ruby
|
869
|
+
describe network_acl('my-network-acl') do
|
870
|
+
it { should have_subnet('my-subnet') }
|
871
|
+
end
|
872
|
+
```
|
873
|
+
|
874
|
+
|
875
|
+
### belong_to_vpc
|
450
876
|
|
451
877
|
```ruby
|
452
878
|
describe network_acl('my-network-acl') do
|
453
|
-
it { should exist }
|
454
879
|
it { should belong_to_vpc('my-vpc') }
|
455
|
-
|
880
|
+
end
|
881
|
+
```
|
882
|
+
|
883
|
+
|
884
|
+
### its(:inbound), its(:outbound), its(:inbound_entries_count), its(:outbound_entries_count)
|
885
|
+
|
886
|
+
```ruby
|
887
|
+
describe network_acl('my-network-acl') do
|
456
888
|
its(:inbound) { should be_allowed(80).protocol('tcp').source('123.0.456.789/32') }
|
457
889
|
its(:inbound) { should be_denied.rule_number('*').source('0.0.0.0/0') }
|
458
890
|
its(:outbound) { should be_allowed.protocol('ALL').source('0.0.0.0/0') }
|
@@ -466,20 +898,35 @@ end
|
|
466
898
|
|
467
899
|
DirectconnectVirtualInterface resource type.
|
468
900
|
|
469
|
-
|
470
|
-
|
471
|
-
|
901
|
+
```ruby
|
902
|
+
describe directconnect_virtual_interface('my-directconnect-virtual-interface') do
|
903
|
+
it { should exist }
|
904
|
+
it { should be_available }
|
905
|
+
its(:connection_id) { should eq 'dxcon-abcd5fgh' }
|
906
|
+
its(:virtual_interface_id) { should eq 'dxvif-aabbccdd' }
|
907
|
+
its(:amazon_address) { should eq '170.252.252.1/30' }
|
908
|
+
its(:customer_address) { should eq '123.456.789.2/30' }
|
909
|
+
its(:virtual_gateway_id) { should eq 'vgw-d234e5f6' }
|
910
|
+
end
|
911
|
+
```
|
472
912
|
|
473
|
-
### be_confirming
|
474
913
|
|
475
|
-
###
|
914
|
+
### exist
|
476
915
|
|
477
|
-
|
916
|
+
```ruby
|
917
|
+
describe directconnect_virtual_interface('my-directconnect-virtual-interface') do
|
918
|
+
it { should exist }
|
919
|
+
end
|
920
|
+
```
|
478
921
|
|
479
|
-
### be_pending
|
480
922
|
|
481
|
-
### be_rejected
|
923
|
+
### be_confirming, be_verifying, be_pending, be_available, be_deleting, be_deleted, be_rejected
|
482
924
|
|
483
|
-
|
925
|
+
```ruby
|
926
|
+
describe directconnect_virtual_interface('my-directconnect-virtual-interface') do
|
927
|
+
it { should exist }
|
928
|
+
it { should be_available }
|
929
|
+
end
|
930
|
+
```
|
484
931
|
|
485
932
|
#### its(:owner_account), its(:virtual_interface_id), its(:location), its(:connection_id), its(:virtual_interface_type), its(:virtual_interface_name), its(:vlan), its(:asn), its(:auth_key), its(:amazon_address), its(:customer_address), its(:virtual_interface_state), its(:customer_router_config), its(:virtual_gateway_id)
|