Sha256: f74cac6088e0a42bb12b8d25905e2f80a43f21079b531ac51fd7c128ce40e3ad

Contents?: true

Size: 816 Bytes

Versions: 45

Compression:

Stored size: 816 Bytes

Contents

module Fog
  module OpenStack
    class Planning
      class Real
        def list_roles(options = {})
          request(
            :expects => [200, 204],
            :method  => 'GET',
            :path    => 'roles',
            :query   => options
          )
        end
      end

      class Mock
        def list_roles(_options = {})
          response = Excon::Response.new
          response.status = [200, 204][rand(2)]
          response.body = [
            {
              "description" => "OpenStack hypervisor node. Can be wrapped in a ResourceGroup for scaling.\n",
              "name"        => "compute",
              "uuid"        => "f72c0656-5696-4c66-81a5-d6d88a48e385",
              "version"     => 1
            }
          ]
          response
        end
      end
    end
  end
end

Version data entries

45 entries across 43 versions & 5 rubygems

Version Path
fog-openstack-1.1.3 lib/fog/openstack/planning/requests/list_roles.rb
fog-openstack-1.1.2 lib/fog/openstack/planning/requests/list_roles.rb
fog-openstack-fork-99 lib/fog/openstack/planning/requests/list_roles.rb
fog-openstack-1.1.0 lib/fog/openstack/planning/requests/list_roles.rb
fog-openstack-1.1.0.pre lib/fog/openstack/planning/requests/list_roles.rb
fog-openstack-apibank-1.0.102 lib/fog/openstack/planning/requests/list_roles.rb
fog-openstack-1.0.11 lib/fog/openstack/planning/requests/list_roles.rb
fog-openstack-apibank-1.0.101 lib/fog/openstack/planning/requests/list_roles.rb
fog-openstack-1.0.10 lib/fog/openstack/planning/requests/list_roles.rb
fog-openstack-1.0.9 lib/fog/openstack/planning/requests/list_roles.rb
fog-openstack-0.1.31 lib/fog/planning/openstack/requests/list_roles.rb
fog-openstack-0.3.10 lib/fog/planning/openstack/requests/list_roles.rb
fog-openstack-1.0.8 lib/fog/openstack/planning/requests/list_roles.rb
fog-openstack-0.1.30 lib/fog/planning/openstack/requests/list_roles.rb
fog-openstack-1.0.7 lib/fog/openstack/planning/requests/list_roles.rb
fog-openstack-0.1.29 lib/fog/planning/openstack/requests/list_roles.rb
fog-openstack-0.3.9 lib/fog/planning/openstack/requests/list_roles.rb
fog-openstack-1.0.6 lib/fog/openstack/planning/requests/list_roles.rb
fog-openstack-0.1.28 lib/fog/planning/openstack/requests/list_roles.rb
fog-openstack-1.0.5 lib/fog/openstack/planning/requests/list_roles.rb