Sha256: df83de19b912b140938fb7d94ccc6c2a80881c54b19547589ae4742b5b0d2459

Contents?: true

Size: 740 Bytes

Versions: 27

Compression:

Stored size: 740 Bytes

Contents

# coding: utf-8
Shindo.tests('Fog::Volume[:sakuracloud] | list_archives request', ['sakuracloud', 'volume']) do

  @archive_format = {
    'Index'        => Integer,
    'ID'           => Integer,
    'Name'         => String,
    'SizeMB'       => Integer,
    'Plan'         => Hash
  }

  tests('success') do

    tests('#list_archives') do
      archives = sakuracloud_volume_service.list_archives
      test 'returns a Hash' do
        archives.body.is_a? Hash
      end
      if Fog.mock?
        tests('Archives').formats(@archive_format, false) do
          archives.body['Archives'].first
        end
      else
        returns(200) { archives.status }
        returns(false) { archives.body.empty? }
      end
    end

  end

end

Version data entries

27 entries across 25 versions & 3 rubygems

Version Path
vagrant-packet-0.1.1 vendor/bundle/ruby/2.3.0/gems/fog-sakuracloud-1.7.5/tests/sakuracloud/requests/volume/archives_tests.rb
vagrant-packet-0.1.1 vendor/bundle/ruby/2.5.0/gems/fog-sakuracloud-1.7.5/tests/sakuracloud/requests/volume/archives_tests.rb
vagrant-packet-0.1.1 vendor/bundle/ruby/2.4.0/gems/fog-sakuracloud-1.7.5/tests/sakuracloud/requests/volume/archives_tests.rb
fog-sakuracloud-1.7.5 tests/sakuracloud/requests/volume/archives_tests.rb
fog-sakuracloud-1.7.4 tests/sakuracloud/requests/volume/archives_tests.rb
fog-sakuracloud-1.7.3 tests/sakuracloud/requests/volume/archives_tests.rb
fog-sakuracloud-1.7.2 tests/sakuracloud/requests/volume/archives_tests.rb
fog-sakuracloud-1.7.1 tests/sakuracloud/requests/volume/archives_tests.rb
fog-sakuracloud-1.7.0 tests/sakuracloud/requests/volume/archives_tests.rb
fog-sakuracloud-1.6.0 tests/sakuracloud/requests/volume/archives_tests.rb
fog-sakuracloud-1.5.2 tests/sakuracloud/requests/volume/archives_tests.rb
fog-sakuracloud-1.5.1 tests/sakuracloud/requests/volume/archives_tests.rb
fog-sakuracloud-1.5.0 tests/sakuracloud/requests/volume/archives_tests.rb
fog-sakuracloud-1.4.0 tests/sakuracloud/requests/volume/archives_tests.rb
fog-sakuracloud-1.3.3 tests/sakuracloud/requests/volume/archives_tests.rb
fog-sakuracloud-1.3.2 tests/sakuracloud/requests/volume/archives_tests.rb
fog-sakuracloud-1.3.1 tests/sakuracloud/requests/volume/archives_tests.rb
fog-sakuracloud-1.3.0 tests/sakuracloud/requests/volume/archives_tests.rb
fog-sakuracloud-1.2.0 tests/sakuracloud/requests/volume/archives_tests.rb
fog-sakuracloud-1.1.1 tests/sakuracloud/requests/volume/archives_tests.rb