Sha256: bb0912a9bf92d8069bae5bf8b1731241be7dad378fc9dc0eed0498591d57826b
Contents?: true
Size: 1.26 KB
Versions: 23
Compression:
Stored size: 1.26 KB
Contents
require "spec_helper" describe Brightbox::Account do before do Brightbox.config = config_from_contents(contents) end describe ".all" do context "when connected using an application", vcr: true do let(:contents) { USER_APP_CONFIG_CONTENTS } it "returns a collection of Accounts" do expect(Brightbox::Account.all).to be_kind_of(Array) Brightbox::Account.all.each do |account| expect(account).to be_kind_of(Fog::Compute::Brightbox::Account) end end it "returns resources on the same connection" do Brightbox::Account.all.each do |account| expect(account.service).to eql(Brightbox::Account.conn) end end end context "when connected using an client", vcr: true do let(:contents) { API_CLIENT_CONFIG_CONTENTS } it "returns a collection of Accounts" do expect(Brightbox::Account.all).to be_kind_of(Array) Brightbox::Account.all.each do |account| expect(account).to be_kind_of(Fog::Compute::Brightbox::Account) end end it "returns resources on the same connection" do Brightbox::Account.all.each do |account| expect(account.service).to eql(Brightbox::Account.conn) end end end end end
Version data entries
23 entries across 23 versions & 1 rubygems