Sha256: d5312bb5ded080432b6a1f59650a8eca9a8a9237cb60bc4e84efb1ae3a991455

Contents?: true

Size: 813 Bytes

Versions: 36

Compression:

Stored size: 813 Bytes

Contents

Shindo.tests('Rackspace::Servers | flavor requests', ['rackspace']) do

  @flavor_format = {
    'disk'  => Integer,
    'id'    => Integer,
    'name'  => String,
    'ram'   => Integer
  }

  tests('success') do

    tests('#get_flavor_details(1)').formats(@flavor_format) do
      Rackspace[:servers].get_flavor_details(1).body['flavor']
    end

    tests('#list_flavors').formats({'flavors' => [Rackspace::Servers::Formats::SUMMARY]}) do
      Rackspace[:servers].list_flavors.body
    end

    tests('#list_flavors_detail').formats({'flavors' => [@flavor_format]}) do
      Rackspace[:servers].list_flavors_detail.body
    end

  end

  tests('failure') do

    tests('#get_flavor_details(0)').raises(Fog::Rackspace::Servers::NotFound) do
      Rackspace[:servers].get_flavor_details(0)
    end

  end

end

Version data entries

36 entries across 36 versions & 2 rubygems

Version Path
fog-0.2.30 tests/rackspace/requests/servers/flavor_tests.rb
fog-0.2.28 tests/rackspace/requests/servers/flavor_tests.rb
fog-0.2.27 tests/rackspace/requests/servers/flavor_tests.rb
fog-0.2.26 tests/rackspace/requests/servers/flavor_tests.rb
fog-0.2.25 tests/rackspace/requests/servers/flavor_tests.rb
fog-0.2.24 tests/rackspace/requests/servers/flavor_tests.rb
tecnh-fog-0.2.23.vpc tests/rackspace/requests/servers/flavor_tests.rb
fog-0.2.23 tests/rackspace/requests/servers/flavor_tests.rb
fog-0.2.22 tests/rackspace/requests/servers/flavor_tests.rb
fog-0.2.21 tests/rackspace/requests/servers/flavor_tests.rb
fog-0.2.20 tests/rackspace/requests/servers/flavor_tests.rb
fog-0.2.19 tests/rackspace/requests/servers/flavor_tests.rb
fog-0.2.18 tests/rackspace/requests/servers/flavor_tests.rb
fog-0.2.17 tests/rackspace/requests/servers/flavor_tests.rb
fog-0.2.16 tests/rackspace/requests/servers/flavor_tests.rb
fog-0.2.15 tests/rackspace/requests/servers/flavor_tests.rb
fog-0.2.14 tests/rackspace/requests/servers/flavor_tests.rb
fog-0.2.13 tests/rackspace/requests/servers/flavor_tests.rb
fog-0.2.12 tests/rackspace/requests/servers/flavor_tests.rb
fog-0.2.11 tests/rackspace/requests/servers/flavor_tests.rb