diff --git a/tests/hp/models/block_storage/volume_tests.rb b/tests/hp/models/block_storage/volume_tests.rb new file mode 100644 index 000000000..e52c1141c --- /dev/null +++ b/tests/hp/models/block_storage/volume_tests.rb @@ -0,0 +1,21 @@ +Shindo.tests("Fog::BlockStorage[:hp] | volumes", ['hp', 'block_storage']) do + + model_tests(Fog::BlockStorage[:hp].volumes, {:name => "fogvoltests", :description => "fogvoltests-desc", :size => 1}, true) + + tests("new volume") do + @volume = Fog::BlockStorage[:hp].volumes.create(:name => "testvol", :size => 1) + @volume.wait_for { ready? } unless Fog.mocking? + + test("get(#{@volume.id})") do + Fog::BlockStorage[:hp].volumes.get(@volume.id) != nil? + end + + test("has_attachments?") do + @volume.has_attachments? == false + end + after do + @volume.destroy + end + end + +end diff --git a/tests/hp/requests/block_storage/volume_tests.rb b/tests/hp/requests/block_storage/volume_tests.rb index db4def0e2..b7d7f5eec 100644 --- a/tests/hp/requests/block_storage/volume_tests.rb +++ b/tests/hp/requests/block_storage/volume_tests.rb @@ -2,12 +2,12 @@ Shindo.tests('Fog::BlockStorage[:hp] | volume requests', ['hp', 'block_storage'] @volume_format = { 'status' => String, - 'displayDescription' => String, + 'displayDescription' => Fog::Nullable::String, 'availabilityZone' => String, - 'displayName' => String, + 'displayName' => Fog::Nullable::String, 'attachments' => [Fog::Nullable::Hash], 'volumeType' => Fog::Nullable::String, - 'snapshotId' => String, + 'snapshotId' => Fog::Nullable::String, 'size' => Integer, 'id' => Integer, 'createdAt' => String,