Sha256: f4fc994a3889e5f1f4509570cf10fbf9abd97469e56281cf952577974b178dde

Contents?: true

Size: 737 Bytes

Versions: 11

Compression:

Stored size: 737 Bytes

Contents

Shindo.tests("Fog::Compute[:ovirt] | update_volume request", ["ovirt"]) do
  compute = Fog::Compute[:ovirt]
  if compute.servers.all(:search => "fog-*").empty?
    compute.create_vm(:name => "fog-" + Time.now.to_i.to_s, :cluster_name => "Default")
  end
  vm_id = compute.servers.all(:search => "fog-*").last

  tests("The expected options") do
    raises(ArgumentError, "raises ArgumentError when vm id is missing") { compute.update_volume(nil, :id => 1) }
    raises(ArgumentError, "raises ArgumentError when disk_id option is missing") { compute.update_volume(1, :any => 1) }
  end

  tests("The response should") do
    response = compute.update_volume(vm_id, :id => 1)
    test("be a success") { response ? true : false }
  end
end

Version data entries

11 entries across 9 versions & 2 rubygems

Version Path
fog-ovirt-1.1.2 tests/ovirt/requests/compute/v3/update_volume_tests.rb
fog-ovirt-1.1.1 tests/ovirt/requests/compute/v3/update_volume_tests.rb
vagrant-packet-0.1.1 vendor/bundle/ruby/2.5.0/gems/fog-ovirt-1.1.0/tests/ovirt/requests/compute/v3/update_volume_tests.rb
vagrant-packet-0.1.1 vendor/bundle/ruby/2.4.0/gems/fog-ovirt-1.1.0/tests/ovirt/requests/compute/v3/update_volume_tests.rb
vagrant-packet-0.1.1 vendor/bundle/ruby/2.3.0/gems/fog-ovirt-1.1.0/tests/ovirt/requests/compute/v3/update_volume_tests.rb
fog-ovirt-1.1.0 tests/ovirt/requests/compute/v3/update_volume_tests.rb
fog-ovirt-1.0.4 tests/ovirt/requests/compute/v3/update_volume_tests.rb
fog-ovirt-1.0.3 tests/ovirt/requests/compute/v3/update_volume_tests.rb
fog-ovirt-1.0.2 tests/ovirt/requests/compute/v3/update_volume_tests.rb
fog-ovirt-1.0.1 tests/ovirt/requests/compute/update_volume_tests.rb
fog-ovirt-1.0.0 tests/ovirt/requests/compute/update_volume_tests.rb