Sha256: 228436bf14ef5ec2836bb69ceab1bd1bd9cbb4c414a805a06214988a2dd7ff44

Contents?: true

Size: 1.04 KB

Versions: 381

Compression:

Stored size: 1.04 KB

Contents

require 'spec_helper'

describe Travis::Client::Account do
  context "from all accounts" do
    let(:session) { Travis::Client.new }
    subject { session.accounts.first }
    its(:name) { should be == 'Konstantin Haase' }
    its(:login) { should be == 'rkh' }
    its(:type) { should be == 'user' }
    its(:repos_count) { should be == 200 }
    its(:inspect) { should be == "#<Travis::Client::Account: rkh>" }
  end

  context "known account" do
    let(:session) { Travis::Client.new }
    subject { session.account('rkh') }
    its(:name) { should be == 'Konstantin Haase' }
    its(:login) { should be == 'rkh' }
    its(:type) { should be == 'user' }
    its(:repos_count) { should be == 200 }
    its(:inspect) { should be == "#<Travis::Client::Account: rkh>" }
  end

  context "known account" do
    let(:session) { Travis::Client.new }
    subject { session.account('foo') }
    its(:name) { should be_nil }
    its(:login) { should be == 'foo' }
    its(:type) { should be_nil }
    its(:inspect) { should be == "#<Travis::Client::Account: foo>" }
  end
end

Version data entries

381 entries across 381 versions & 3 rubygems

Version Path
travis-1.8.14.travis.1178.9 spec/client/account_spec.rb
travis-1.8.14.travis.1175.9 spec/client/account_spec.rb
travis-1.8.14.travis.1172.9 spec/client/account_spec.rb
travis-1.8.14.travis.1164.9 spec/client/account_spec.rb
travis-1.8.14.travis.1163.9 spec/client/account_spec.rb
travis-1.8.14.travis.1162.9 spec/client/account_spec.rb
travis-1.8.14.travis.1160.9 spec/client/account_spec.rb
travis-1.8.13 spec/client/account_spec.rb
travis-1.8.14.travis.1156.9 spec/client/account_spec.rb
travis-1.8.14.travis.1155.9 spec/client/account_spec.rb
travis-1.8.13.travis.1152.9 spec/client/account_spec.rb
travis-1.8.13.travis.1148.9 spec/client/account_spec.rb
travis-1.8.12 spec/client/account_spec.rb
travis-1.8.13.travis.1141.9 spec/client/account_spec.rb
travis-1.8.12.travis.1136.9 spec/client/account_spec.rb
travis-1.8.12.travis.1135.9 spec/client/account_spec.rb
travis-1.8.12.travis.1125.9 spec/client/account_spec.rb
travis-1.8.12.pre.rc1 spec/client/account_spec.rb
travis-1.8.12.travis.1116.9 spec/client/account_spec.rb
travis-1.8.12.travis.1111.9 spec/client/account_spec.rb