Sha256: 8b103f7bc99e90f8078fd3fb02b64386a9f7b8730fb8388d6b130673615a0603

Contents?: true

Size: 1.21 KB

Versions: 39

Compression:

Stored size: 1.21 KB

Contents

Shindo.tests('AWS::IAM | group policy requests', ['aws']) do

  unless Fog.mocking?
    AWS[:iam].create_group('fog_group_policy_tests')
  end

  tests('success') do

    @policy = {"Statement" => [{"Effect" => "Allow", "Action" => "*", "Resource" => "*"}]}

    tests("#put_group_policy('fog_group_policy_tests', 'fog_policy', #{@policy.inspect})").formats(AWS::IAM::Formats::BASIC) do
      pending if Fog.mocking?
      AWS[:iam].put_group_policy('fog_group_policy_tests', 'fog_policy', @policy).body
    end

    @group_policies_format = {
      'IsTruncated' => Fog::Boolean,
      'PolicyNames' => [String],
      'RequestId'   => String
    }

    tests("list_group_policies('fog_group_policy_tests')").formats(@group_policies_format) do
      pending if Fog.mocking?
      AWS[:iam].list_group_policies('fog_group_policy_tests').body
    end

    tests("#delete_group_policy('fog_group_policy_tests', 'fog_policy')").formats(AWS::IAM::Formats::BASIC) do
      pending if Fog.mocking?
      AWS[:iam].delete_group_policy('fog_group_policy_tests', 'fog_policy').body
    end

  end

  tests('failure') do
    test('failing conditions')
  end

  unless Fog.mocking?
    AWS[:iam].delete_group('fog_group_policy_tests')
  end

end

Version data entries

39 entries across 39 versions & 4 rubygems

Version Path
brightbox-cli-0.13.1 lib/brightbox-cli/vendor/fog/tests/aws/requests/iam/group_policy_tests.rb
brightbox-cli-0.13.0 lib/brightbox-cli/vendor/fog/tests/aws/requests/iam/group_policy_tests.rb
fog-0.11.0 tests/aws/requests/iam/group_policy_tests.rb
fog-0.10.0 tests/aws/requests/iam/group_policy_tests.rb
fog4encbs-0.9.0.1 tests/aws/requests/iam/group_policy_tests.rb
fog4encbs-0.9.0 tests/aws/requests/iam/group_policy_tests.rb
fog-0.9.0 tests/aws/requests/iam/group_policy_tests.rb
fog-0.8.2 tests/aws/requests/iam/group_policy_tests.rb
fog-0.8.1 tests/aws/requests/iam/group_policy_tests.rb
fog-0.8.0 tests/aws/requests/iam/group_policy_tests.rb
fog-0.7.2 tests/aws/requests/iam/group_policy_tests.rb
fog-0.7.1 tests/aws/requests/iam/group_policy_tests.rb
fog-0.7.0 tests/aws/requests/iam/group_policy_tests.rb
fog-0.6.0 tests/aws/requests/iam/group_policy_tests.rb
fog-0.5.3 tests/aws/requests/iam/group_policy_tests.rb
fog-0.5.2 tests/aws/requests/iam/group_policy_tests.rb
fog-0.5.1 tests/aws/requests/iam/group_policy_tests.rb
fog-0.5.0 tests/aws/requests/iam/group_policy_tests.rb
phpfog-fog-0.4.1.3 tests/aws/requests/iam/group_policy_tests.rb
phpfog-fog-0.4.1.2 tests/aws/requests/iam/group_policy_tests.rb