travis 1.6.18.travis.607.5 → 1.6.18.travis.608.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,15 +1,15 @@
1
1
  ---
2
2
  !binary "U0hBMQ==":
3
3
  metadata.gz: !binary |-
4
- ZjI0YmE3ZTI5NDJjMWYwMjE2ZWE2YjdlNjNjYzcyMDYxYTA0Yzg4YQ==
4
+ YWQzYTI1MGRiOGE2OWQ2YTFkMDUzMTg4NTgyYWM4MjVhZjdjNGUyZA==
5
5
  data.tar.gz: !binary |-
6
- YzVmYjU5M2YyYzFjZWVlNDgxNTgwMzg1ZjA5MDAzOTA5NGQzNWUwZg==
6
+ M2VmMTFkMzFkY2E0N2IxNWQ1NTVjZGM1YjJjZWM5NDMyNTNjZTFmZA==
7
7
  SHA512:
8
8
  metadata.gz: !binary |-
9
- MzM4YTUyMzViZjJhZWNiODQzYzNlOTg0ZDI5YWVmYzJmMTZjZmFjNWEzZTNi
10
- M2NmMGEyN2JjOTc2NTI3YjQ5MWQwODc1OTMwZGFmZmViODk2YmU4MzQxMGE4
11
- MzIyMjk1YzMyODJlZDU5ODY2YWZjODgzMDNkZDYzNzI4NzQwOTc=
9
+ ZjRiYWFiYzVlMjJmMjc1YjlmZTczZTYwMGY2ZmIwNDllNDNiZGRhNGE2MGMx
10
+ NGE1MGUxYmExNDBkZjkxYTRiMzY4YTE3ZWM5OGZlNTg3ZGU4M2RmN2Y1MDdl
11
+ NzJhNDU0NTZiN2UyMWIyNDZiYTJhNmQ4MDJhZjAzYTQ0OGI2MmI=
12
12
  data.tar.gz: !binary |-
13
- OTc1YTJhZjE3Nzg4NDM0YjllNjcyOTE2OGJjMGJjN2Q5NjBiZTE1MzI0NjA1
14
- ZDE0ZjczNzEyNTM5MDE4ZjJkNzgxOWU5YmZlZmNlMDZjMjRmZGFjZTUyY2Iw
15
- NTY3ZDZkZjgwNjI4ZDExNTEwMWRjODAwMmU3NWY1ZjlhN2FhNjY=
13
+ OTcwODFmMmQ5MDFkN2YwNzFmNWRlODdlMjQzMjEzZjFjMDQ5ZjYxZjFjNjg5
14
+ YjU1ZWYzNTJmNWY0ODE4YjEyZjgwNmNmYTI2NTBjMThlYTAwNTNlMThmNjY1
15
+ YjQ0OWM4MDE0Yjg1Yzg0M2M2ODU2YjZiNGJmZGJjMWYyNDRiMDY=
data/README.md CHANGED
@@ -2051,6 +2051,7 @@ If you have the old `travis-cli` gem installed, you should `gem uninstall travis
2051
2051
  * Announce repository slug when first detected, ask for confirmation in interactive mode.
2052
2052
  * Have `travis repos` only print repository slugs in non-interactive mode.
2053
2053
  * Add `travis/auto_login` and `travis/pro/auto_login` to the Ruby API for easy authentication.
2054
+ * Add `fingerprint` to `Repository#public_key`.
2054
2055
 
2055
2056
  **1.6.17** (July 25, 2014)
2056
2057
 
@@ -5,10 +5,11 @@ module Travis
5
5
  module Client
6
6
  class Repository < Entity
7
7
  class Key
8
- attr_reader :to_s
8
+ attr_reader :to_s, :fingerprint
9
9
 
10
- def initialize(data)
10
+ def initialize(data, fingerprint)
11
11
  @to_s = data
12
+ @fingerprint = fingerprint
12
13
  end
13
14
 
14
15
  def encrypt(value)
@@ -52,7 +53,7 @@ module Travis
52
53
  def public_key
53
54
  attributes["public_key"] ||= begin
54
55
  payload = session.get_raw("/repos/#{id}/key")
55
- Key.new(payload.fetch('key'))
56
+ Key.new(payload.fetch('key'), payload.fetch('fingerprint'))
56
57
  end
57
58
  end
58
59
 
@@ -61,8 +62,7 @@ module Travis
61
62
  end
62
63
 
63
64
  def public_key=(key)
64
- key = Key.new(key) unless key.is_a? Key
65
- set_attribute(:public_key, key)
65
+ # ignored
66
66
  end
67
67
 
68
68
  alias key public_key
@@ -32,4 +32,8 @@ describe Travis::Client::Repository do
32
32
  it { should_not be_green }
33
33
  it { should_not be_yellow }
34
34
  it { should be_unsuccessful }
35
+
36
+ it 'should expose the pubkey fingerprint' do
37
+ subject.public_key.fingerprint.should be == 'foobar'
38
+ end
35
39
  end
@@ -691,7 +691,7 @@ module Travis
691
691
  end
692
692
 
693
693
  get '/repos/891/key' do
694
- {"key"=>RAILS_KEY}.to_json
694
+ {"key"=>RAILS_KEY, "fingerprint"=>"foobar"}.to_json
695
695
  end
696
696
 
697
697
  get '/accounts/' do
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: travis
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.6.18.travis.607.5
4
+ version: 1.6.18.travis.608.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Konstantin Haase