Sha256: 683dd36c80f5b980a2e5e58ae4e499414a69f63bdbb57dd6ed90cb667f3ec5e2

Contents?: true

Size: 1.38 KB

Versions: 217

Compression:

Stored size: 1.38 KB

Contents

require 'spec_helper'

describe Travis::Client::Repository do
  let(:session) { Travis::Client.new }
  subject { session.repo('rails/rails') }

  its(:slug) { should be == 'rails/rails' }
  its(:description) { should_not be_empty }
  its(:last_build_id) { should be == 4125095 }
  its(:last_build_number) { should be == '6180' }
  its(:last_build_state) { should be == 'failed' }
  its(:last_build_duration) { should be == 5019 }
  its(:last_build_started_at) { should be_a(Time) }
  its(:last_build_finished_at) { should be_nil }
  its(:inspect) { should be == "#<Travis::Client::Repository: rails/rails>" }
  its(:key) { should be_a(Travis::Client::Repository::Key) }
  its(:last_build) { should be_a(Travis::Client::Build) }
  its(:color) { should be == 'red' }
  its(:github_language) { should be == 'Ruby' }
  its(:owner_name) { should be == 'rails' }
  its(:owner) { should be == session.account("rails") }

  it { should_not be_pending  }
  it { should     be_started  }
  it { should     be_finished }
  it { should_not be_passed   }
  it { should_not be_errored  }
  it { should     be_failed   }
  it { should_not be_canceled }
  it { should     be_created  }
  it { should     be_red      }
  it { should_not be_green    }
  it { should_not be_yellow   }
  it { should be_unsuccessful }

  it 'should expose the pubkey fingerprint' do
    subject.public_key.fingerprint.should be == 'foobar'
  end
end

Version data entries

217 entries across 217 versions & 3 rubygems

Version Path
travis-1.11.1 spec/client/repository_spec.rb
travis-1.11.0 spec/client/repository_spec.rb
travis-1.10.1.travis.1341.9 spec/client/repository_spec.rb
travis-1.10.1.travis.1321.9 spec/client/repository_spec.rb
travis-1.10.1.travis.1312.9 spec/client/repository_spec.rb
travis-1.10.1.travis.1311.9 spec/client/repository_spec.rb
travis-1.10.1.travis.1305.9 spec/client/repository_spec.rb
travis-1.10.0 spec/client/repository_spec.rb
travis-1.9.2.travis.1304.9 spec/client/repository_spec.rb
travis-1.9.2.travis.1303.9 spec/client/repository_spec.rb
travis-1.10.0.pre.rc4 spec/client/repository_spec.rb
travis-1.10.0.pre.rc3 spec/client/repository_spec.rb
travis-1.10.0.pre.rc2 spec/client/repository_spec.rb
travis-1.9.2.travis.1288.9 spec/client/repository_spec.rb
travis-1.9.2.travis.1285.9 spec/client/repository_spec.rb
travis-1.9.2.travis.1279.9 spec/client/repository_spec.rb
travis-1.10.0.pre.rc1 spec/client/repository_spec.rb
travis-1.9.2.travis.1254.9 spec/client/repository_spec.rb
travis-1.9.2.travis.1236.9 spec/client/repository_spec.rb
travis-1.9.2.travis.1224.9 spec/client/repository_spec.rb