diff --git a/tests/compute/models/aws/security_group_tests.rb b/tests/compute/models/aws/security_group_tests.rb index a2707813c..ac7ce4e25 100644 --- a/tests/compute/models/aws/security_group_tests.rb +++ b/tests/compute/models/aws/security_group_tests.rb @@ -12,6 +12,21 @@ Shindo.tests("Fog::Compute[:aws] | security_group", ['aws']) do @group.description == " fog group desc " end + @other_group = Fog::Compute[:aws].security_groups.create(:name => 'other group', :description => 'another group') + + test("authorize access by another security group") do + @group.authorize_group_and_owner(@other_group.name, @other_group.owner_id) + @group.reload + @group.ip_permissions.size == 3 + end + + test("revoke access from another security group") do + @group.revoke_group_and_owner(@other_group.name, @other_group.owner_id) + @group.reload + @group.ip_permissions.size == 0 + end + + @other_group.destroy @group.destroy end end