Sha256: 318a81075096722443bf205182c59d4ddc942d9d95a1a41e46b792a66b47a9d6

Contents?: true

Size: 1.23 KB

Versions: 64

Compression:

Stored size: 1.23 KB

Contents

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

  unless Fog.mocking?
    Fog::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?
      Fog::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?
      Fog::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?
      Fog::AWS[:iam].delete_group_policy('fog_group_policy_tests', 'fog_policy').body
    end

  end

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

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

end

Version data entries

64 entries across 64 versions & 17 rubygems

Version Path
gapinc-fog-1.12.1.2.1 tests/aws/requests/iam/group_policy_tests.rb
fog-maestrodev-1.15.0.20130927082724 tests/aws/requests/iam/group_policy_tests.rb
fog-maestrodev-1.15.0.20130829165835 tests/aws/requests/iam/group_policy_tests.rb
fog-1.15.0 tests/aws/requests/iam/group_policy_tests.rb
gapinc-fog-1.14.0 tests/aws/requests/iam/group_policy_tests.rb
fog-maestrodev-1.14.0.20130806165225 tests/aws/requests/iam/group_policy_tests.rb
fog-1.14.0 tests/aws/requests/iam/group_policy_tests.rb
fog-1.13.0 tests/aws/requests/iam/group_policy_tests.rb
gapinc-fog-1.12.1.2 tests/aws/requests/iam/group_policy_tests.rb
gapinc-fog-1.12.1.1 tests/aws/requests/iam/group_policy_tests.rb
gapinc-fog-1.12.1a tests/aws/requests/iam/group_policy_tests.rb
gapinc-fog-1.12.1 tests/aws/requests/iam/group_policy_tests.rb
fog-1.12.1 tests/aws/requests/iam/group_policy_tests.rb
fog-1.12.0 tests/aws/requests/iam/group_policy_tests.rb
hpfog-0.0.20 tests/aws/requests/iam/group_policy_tests.rb
vagrant-shell-0.2.6 vendor/bundle/gems/fog-1.10.1/tests/aws/requests/iam/group_policy_tests.rb
vagrant-shell-0.2.5 vendor/bundle/gems/fog-1.10.1/tests/aws/requests/iam/group_policy_tests.rb
fog-nirvanix-1.8.2 tests/aws/requests/iam/group_policy_tests.rb
fog-1.11.1 tests/aws/requests/iam/group_policy_tests.rb
fog-1.11.0 tests/aws/requests/iam/group_policy_tests.rb