Sha256: a6cedbaaa5c68eae1029082a086811c77cbb7fd7ae1cc953bb461614be6708a9

Contents?: true

Size: 1.12 KB

Versions: 5

Compression:

Stored size: 1.12 KB

Contents

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

  tests('success') do

    tests("#get_account") do
      pending if Fog.mocking?
      result = Fog::Compute[:brightbox].get_account
      formats(Brightbox::Compute::Formats::Full::ACCOUNT) { result }
      test("ftp password is blanked") { result["library_ftp_password"].nil?  }
    end

    update_options = {:name => "Fog@#{Time.now.iso8601}"}
    tests("#update_account(#{update_options.inspect})") do
      pending if Fog.mocking?
      result = Fog::Compute[:brightbox].update_account(update_options)
      formats(Brightbox::Compute::Formats::Full::ACCOUNT) { result }
    end

    tests("#reset_ftp_password_account") do
      pending if Fog.mocking?
      result = Fog::Compute[:brightbox].reset_ftp_password_account
      formats(Brightbox::Compute::Formats::Full::ACCOUNT) { result }
      test("new ftp password is visible") { ! result["library_ftp_password"].nil?  }
    end

  end

  tests('failure') do

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

  end

end

Version data entries

5 entries across 5 versions & 3 rubygems

Version Path
brightbox-cli-0.17.1 lib/brightbox-cli/vendor/fog/tests/brightbox/requests/compute/account_tests.rb
brightbox-cli-0.17.0 lib/brightbox-cli/vendor/fog/tests/brightbox/requests/compute/account_tests.rb
fog-1.1.2 tests/brightbox/requests/compute/account_tests.rb
fog_tractical-1.1.4 tests/brightbox/requests/compute/account_tests.rb
fog_tractical-1.1.3 tests/brightbox/requests/compute/account_tests.rb