Sha256: aa321b7adc274b10258b396dee52b3fbfb9e413e0fdb259090b500e827cb8355

Contents?: true

Size: 796 Bytes

Versions: 14

Compression:

Stored size: 796 Bytes

Contents

module Fog
  module Compute
    class Google
      class Mock
        def list_images(project = @project)
          images = data(project)[:images].values
          build_excon_response("kind" => "compute#imageList",
                               "selfLink" => "https://www.googleapis.com/compute/#{api_version}/projects/#{project}/global/images",
                               "id" => "projects/#{project}/global/images",
                               "items" => images)
        end
      end

      class Real
        def list_images(project = nil)
          api_method = @compute.images.list
          project = @project if project.nil?
          parameters = {
            "project" => project
          }

          request(api_method, parameters)
        end
      end
    end
  end
end

Version data entries

14 entries across 14 versions & 1 rubygems

Version Path
fog-google-0.6.0 lib/fog/compute/google/requests/list_images.rb
fog-google-0.5.5 lib/fog/compute/google/requests/list_images.rb
fog-google-0.5.4 lib/fog/compute/google/requests/list_images.rb
fog-google-0.5.3 lib/fog/compute/google/requests/list_images.rb
fog-google-0.5.2 lib/fog/compute/google/requests/list_images.rb
fog-google-0.5.1 lib/fog/compute/google/requests/list_images.rb
fog-google-0.5.0 lib/fog/compute/google/requests/list_images.rb
fog-google-0.4.2 lib/fog/compute/google/requests/list_images.rb
fog-google-0.4.1 lib/fog/compute/google/requests/list_images.rb
fog-google-0.4.0 lib/fog/compute/google/requests/list_images.rb
fog-google-0.3.2 lib/fog/compute/google/requests/list_images.rb
fog-google-0.3.1 lib/fog/compute/google/requests/list_images.rb
fog-google-0.3.0 lib/fog/compute/google/requests/list_images.rb
fog-google-0.2.0 lib/fog/compute/google/requests/list_images.rb