git_hub_bub 0.0.3 → 0.0.4

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,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 15aef8f8f4a8330bceb3f31c0f6c53f3ccfdd26a
4
- data.tar.gz: 2d0d656b6f0edb4fb053a02dca39a06ee5601b54
3
+ metadata.gz: 3104c7e69499c8bd1be1b1603b861c0f07da7ec3
4
+ data.tar.gz: 10135ef6fe2c5c252987a0670d1ebb6ab07e05ac
5
5
  SHA512:
6
- metadata.gz: 75f78ad4c3c8860bcc27da3267c279feb14a36231acc60e5e3b5671b9edd69b84096fa4da15455536b6d4f64e1688845e0e8539e3f6a5a1c94aa848db36faf89
7
- data.tar.gz: c2e68c03e123cb477dbec431b27585c0da96fce9fb6de52b37b6698a5c6077bc2ca168294ce22a29ffb533bf30d8334e8b28b2087b5dd3446b2d29cd80f88a12
6
+ metadata.gz: a95c19a64ad16447255555baa50e9122b9ffbf856033976e5cc78e772c5ec5f890ec811a5fb8f7e282b84cec56d7357711ced340154a6628c4d2f7735a65b033
7
+ data.tar.gz: 71105105b4ff105931465d806bf87225b27d293af7f2ecc9f62083621accc144d4298506ce9b964fd3e8a132caaecbf1a675e7fadf3be6aa13b098320581ef40
data/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # GitHubBub
2
2
 
3
- [![Build Status](https://travis-ci.org/schneems/git_hub_bub.svg?branch=master)](https://travis-ci.org/schneems/git_hub_bub)
3
+ [![Build Status](https://travis-ci.org/schneems/git_hub_bub.png?branch=master)](https://travis-ci.org/schneems/git_hub_bub)
4
4
 
5
5
  A low level GitHub client that makes the disgusting issue of header based url pagination simple.
6
6
 
@@ -213,4 +213,4 @@ A repo that the `WATCH_OWNER` owns. Should be different from `REPO`
213
213
 
214
214
  ## License
215
215
 
216
- MIT
216
+ MIT
@@ -1,7 +1,11 @@
1
+ ## 0.0.4 (06/06/2014)
2
+
3
+ - Fix github auth check
4
+
1
5
  ## 0.0.2 (07/15/2013)
2
6
 
3
7
  - Fix randomly changing github API requirements. (https://github.com/geemus/excon/issues/249#issuecomment-21002566)
4
8
 
5
9
  ## 0.0.1 (05/21/2012)
6
10
 
7
- - Hello World
11
+ - Hello World
@@ -13,7 +13,7 @@ module GitHubBub
13
13
  class << self
14
14
 
15
15
  def valid_token?(token)
16
- Request.get("https://#{ENV['GITHUB_APP_ID']}:#{ENV['GITHUB_APP_SECRET']}@api.github.com/applications/#{ENV['GITHUB_APP_ID']}/tokens/#{token}", {}, token: nil)
16
+ Request.get("https://#{ENV['GITHUB_APP_ID']}:#{ENV['GITHUB_APP_SECRET']}@api.github.com/applications/#{ENV['GITHUB_APP_ID']}/tokens/#{token}", {token: nil})
17
17
  true
18
18
  rescue GitHubBub::RequestError
19
19
  false
@@ -12,7 +12,7 @@ module GitHubBub
12
12
  RETRIES = 1
13
13
 
14
14
  def initialize(url, query = {}, options = {})
15
- self.url = url =~ /^http(\w?)\:\/\// ? url : File.join(BASE_URI, url)
15
+ self.url = url.include?("http") ? url : File.join(BASE_URI, url)
16
16
  self.options = BASE_OPTIONS.merge(options || {})
17
17
  self.options[:query] = query if query && !query.empty?
18
18
  self.options[:headers] = BASE_HEADERS.merge(options[:headers]|| {})
@@ -1,3 +1,3 @@
1
1
  module GitHubBub
2
- VERSION = "0.0.3"
3
- end
2
+ VERSION = "0.0.4"
3
+ end
@@ -6,18 +6,6 @@ class RequestTest < Test::Unit::TestCase
6
6
  GitHubBub::Request.clear_callbacks
7
7
  end
8
8
 
9
- def test_set_url
10
- request = GitHubBub::Request.new('foo')
11
- assert_equal "https://api.github.com/foo", request.url
12
- request = GitHubBub::Request.new('http://foo.com')
13
- assert_equal "http://foo.com", request.url
14
- request = GitHubBub::Request.new('https://bar.com')
15
- assert_equal "https://bar.com", request.url
16
- request = GitHubBub::Request.new('arthurnn/http')
17
- assert_equal "https://api.github.com/arthurnn/http", request.url
18
- request = GitHubBub::Request.new('arthurnn/https')
19
- assert_equal "https://api.github.com/arthurnn/https", request.url
20
- end
21
9
 
22
10
  def test_set_callback
23
11
  request = GitHubBub::Request.new('foo')
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: git_hub_bub
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.3
4
+ version: 0.0.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Richard Schneeman
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-05-09 00:00:00.000000000 Z
11
+ date: 2014-06-06 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rrrretry
@@ -143,7 +143,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
143
143
  version: '0'
144
144
  requirements: []
145
145
  rubyforge_project:
146
- rubygems_version: 2.2.0
146
+ rubygems_version: 2.2.2
147
147
  signing_key:
148
148
  specification_version: 4
149
149
  summary: git_hub_bub makes github requests
@@ -158,3 +158,4 @@ test_files:
158
158
  - test/git_hub_bub/request_test.rb
159
159
  - test/git_hub_bub/response_test.rb
160
160
  - test/test_helper.rb
161
+ has_rdoc: