Sha256: b72b27ebe990756136cd63b438e61bd9964d60778d98c97064a0fb10d3cfc7f4

Contents?: true

Size: 1.06 KB

Versions: 4

Compression:

Stored size: 1.06 KB

Contents

Shindo.tests('Voxel::Compute | image requests', ['voxel']) do

  @images_format = [{
    'id'    => Integer,
    'summary'  => String
  }]

  @image_format = {
    'description'       => String,
    'id'                => Integer,
    'filesystem'        => {
      'size'  => Integer,
      'type'  => String,
      'units' => String,
    },
    'operating_system'  => {
      'admin_username'  => String,
      'architecture'    => Integer,
      'family'          => String,
      'product_family'  => String,
      'product_version' => String,
      'version'         => String
    },
    'summary'           => String
  }

  tests('success') do
    tests('#images_list').formats(@images_format) do
      pending if Fog.mocking?
      Voxel[:compute].images_list
    end

    tests('#images_list(1)').formats([@image_format]) do
      pending if Fog.mocking?
      Voxel[:compute].images_list(1)
    end
  end

  tests('failure') do
    tests('#images_list(0)').raises(Fog::Voxel::Compute::Error) do
      pending if Fog.mocking?
      Voxel[:compute].images_list(0)
    end
  end

end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
fog-0.7.2 tests/compute/requests/voxel/image_tests.rb
fog-0.7.1 tests/compute/requests/voxel/image_tests.rb
fog-0.7.0 tests/compute/requests/voxel/image_tests.rb
fog-0.6.0 tests/compute/requests/voxel/image_tests.rb