Sha256: e5849c1114d65fda8db1c3ae2d04a8f5671b6dda7b70f24097a131b9a6ce52a7

Contents?: true

Size: 706 Bytes

Versions: 27

Compression:

Stored size: 706 Bytes

Contents

# coding: utf-8
Shindo.tests('Fog::Compute[:sakuracloud] | list_ssh_keys request', ['sakuracloud', 'compute']) do

  @sshkey_format = {
    'Index'        => Integer,
    'ID'           => String,
    'Name'           => String,
    'PublicKey'    => String
  }

  tests('success') do

    tests('#list_ssh_keys') do
      sshkeys = sakuracloud_compute_service.list_ssh_keys
      test 'returns a Hash' do
        sshkeys.body.is_a? Hash
      end
      if Fog.mock?
        tests('SSHKeys').formats(@sshkey_format, false) do
          sshkeys.body['SSHKeys'].first
        end
      else
        returns(200) { sshkeys.status }
        returns(false) { sshkeys.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/compute/ssh_keys_tests.rb
vagrant-packet-0.1.1 vendor/bundle/ruby/2.5.0/gems/fog-sakuracloud-1.7.5/tests/sakuracloud/requests/compute/ssh_keys_tests.rb
vagrant-packet-0.1.1 vendor/bundle/ruby/2.4.0/gems/fog-sakuracloud-1.7.5/tests/sakuracloud/requests/compute/ssh_keys_tests.rb
fog-sakuracloud-1.7.5 tests/sakuracloud/requests/compute/ssh_keys_tests.rb
fog-sakuracloud-1.7.4 tests/sakuracloud/requests/compute/ssh_keys_tests.rb
fog-sakuracloud-1.7.3 tests/sakuracloud/requests/compute/ssh_keys_tests.rb
fog-sakuracloud-1.7.2 tests/sakuracloud/requests/compute/ssh_keys_tests.rb
fog-sakuracloud-1.7.1 tests/sakuracloud/requests/compute/ssh_keys_tests.rb
fog-sakuracloud-1.7.0 tests/sakuracloud/requests/compute/ssh_keys_tests.rb
fog-sakuracloud-1.6.0 tests/sakuracloud/requests/compute/ssh_keys_tests.rb
fog-sakuracloud-1.5.2 tests/sakuracloud/requests/compute/ssh_keys_tests.rb
fog-sakuracloud-1.5.1 tests/sakuracloud/requests/compute/ssh_keys_tests.rb
fog-sakuracloud-1.5.0 tests/sakuracloud/requests/compute/ssh_keys_tests.rb
fog-sakuracloud-1.4.0 tests/sakuracloud/requests/compute/ssh_keys_tests.rb
fog-sakuracloud-1.3.3 tests/sakuracloud/requests/compute/ssh_keys_tests.rb
fog-sakuracloud-1.3.2 tests/sakuracloud/requests/compute/ssh_keys_tests.rb
fog-sakuracloud-1.3.1 tests/sakuracloud/requests/compute/ssh_keys_tests.rb
fog-sakuracloud-1.3.0 tests/sakuracloud/requests/compute/ssh_keys_tests.rb
fog-sakuracloud-1.2.0 tests/sakuracloud/requests/compute/ssh_keys_tests.rb
fog-sakuracloud-1.1.1 tests/sakuracloud/requests/compute/ssh_keys_tests.rb