Sha256: c8eaf368c2310185fff81982fb0fc3f3d0a978645b41313b4efde522d7246cbb

Contents?: true

Size: 969 Bytes

Versions: 50

Compression:

Stored size: 969 Bytes

Contents

Shindo.tests('Fog::Compute[:brightbox] | server type requests', ['brightbox']) do

  tests('success') do

    tests("#list_server_types") do
      pending if Fog.mocking?
      result = Fog::Compute[:brightbox].list_server_types
      @server_type_id = result.first["id"]
      formats(Brightbox::Compute::Formats::Collection::SERVER_TYPES, false) { result }
    end

    tests("#get_server_type('#{@server_type_id}')") do
      pending if Fog.mocking?
      result = Fog::Compute[:brightbox].get_server_type(@server_type_id)
      formats(Brightbox::Compute::Formats::Full::SERVER_TYPE, false) { result }
    end

  end

  tests('failure') do

    tests("#get_server_type('typ-00000')").raises(Excon::Errors::NotFound) do
      pending if Fog.mocking?
      Fog::Compute[:brightbox].get_server_type('typ-00000')
    end

    tests("#get_server").raises(ArgumentError) do
      pending if Fog.mocking?
      Fog::Compute[:brightbox].get_server_type
    end

  end

end

Version data entries

50 entries across 50 versions & 15 rubygems

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