Sha256: ec5708b2518555d3267f53872a92a797835dd4b038dcb66023a35c365ddec215

Contents?: true

Size: 658 Bytes

Versions: 65

Compression:

Stored size: 658 Bytes

Contents

require "spec_helper"

describe Brightbox::CollaboratingAccount do
  include_context "collaborating accounts"

  let(:account) { Brightbox::CollaboratingAccount.new(initial_model) }

  describe "#name" do
    context "when initialised with an account" do
      let(:initial_model) { owned_account }

      it "returns account's name" do
        expect(account.name).to eql("Owned account name")
      end
    end

    context "when initialised with a collaboration" do
      let(:initial_model) { active_collaboration }

      it "returns nested account's name" do
        expect(account.name).to eql("Active collaboration name")
      end
    end
  end
end

Version data entries

65 entries across 65 versions & 1 rubygems

Version Path
brightbox-cli-3.1.0 spec/unit/brightbox/collaborating_account/name_spec.rb
brightbox-cli-3.0.1 spec/unit/brightbox/collaborating_account/name_spec.rb
brightbox-cli-3.0.0 spec/unit/brightbox/collaborating_account/name_spec.rb
brightbox-cli-2.12.0 spec/unit/brightbox/collaborating_account/name_spec.rb
brightbox-cli-2.11.2 spec/unit/brightbox/collaborating_account/name_spec.rb
brightbox-cli-2.11.1 spec/unit/brightbox/collaborating_account/name_spec.rb
brightbox-cli-2.11.0 spec/unit/brightbox/collaborating_account/name_spec.rb
brightbox-cli-2.10.0 spec/unit/brightbox/collaborating_account/name_spec.rb
brightbox-cli-2.9.3 spec/unit/brightbox/collaborating_account/name_spec.rb
brightbox-cli-2.9.2 spec/unit/brightbox/collaborating_account/name_spec.rb
brightbox-cli-2.9.1 spec/unit/brightbox/collaborating_account/name_spec.rb
brightbox-cli-2.9.0 spec/unit/brightbox/collaborating_account/name_spec.rb
brightbox-cli-2.8.2 spec/unit/brightbox/collaborating_account/name_spec.rb
brightbox-cli-2.8.1 spec/unit/brightbox/collaborating_account/name_spec.rb
brightbox-cli-2.8.0 spec/unit/brightbox/collaborating_account/name_spec.rb
brightbox-cli-2.7.1 spec/unit/brightbox/collaborating_account/name_spec.rb
brightbox-cli-2.7.0 spec/unit/brightbox/collaborating_account/name_spec.rb
brightbox-cli-2.6.0 spec/unit/brightbox/collaborating_account/name_spec.rb
brightbox-cli-2.5.0 spec/unit/brightbox/collaborating_account/name_spec.rb
brightbox-cli-2.4.1 spec/unit/brightbox/collaborating_account/name_spec.rb