github_api 0.5.4 → 0.6.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (107) hide show
  1. data/README.md +3 -3
  2. data/features/cassettes/events/issue.yml +64 -32
  3. data/features/cassettes/events/network.yml +63 -32
  4. data/features/cassettes/events/org.yml +61 -31
  5. data/features/cassettes/events/performed.yml +63 -32
  6. data/features/cassettes/events/public.yml +61 -31
  7. data/features/cassettes/events/received.yml +63 -32
  8. data/features/cassettes/events/repo.yml +63 -32
  9. data/features/cassettes/gists/comments/all.yml +32 -1
  10. data/features/cassettes/gists/comments/first.yml +32 -1
  11. data/features/cassettes/gists/fork.yml +63 -31
  12. data/features/cassettes/gists/gist.yml +32 -1
  13. data/features/cassettes/gists/gists/public_all.yml +32 -1
  14. data/features/cassettes/gists/gists/starred.yml +60 -29
  15. data/features/cassettes/gists/gists/user_all.yml +87 -1
  16. data/features/cassettes/gists/star.yml +58 -27
  17. data/features/cassettes/gists/starred.yml +32 -1
  18. data/features/cassettes/gists/unstar.yml +54 -25
  19. data/features/cassettes/git_data/references/all.yml +32 -1
  20. data/features/cassettes/git_data/references/all_tags.yml +32 -1
  21. data/features/cassettes/git_data/references/one.yml +32 -1
  22. data/features/cassettes/issues/create.yml +46 -0
  23. data/features/cassettes/issues/edit.yml +44 -0
  24. data/features/cassettes/issues/get.yml +62 -0
  25. data/features/cassettes/issues/list/repo.yml +251 -0
  26. data/features/cassettes/issues/list/user.yml +44 -0
  27. data/features/cassettes/orgs/get.yml +60 -30
  28. data/features/cassettes/orgs/list/oauth_user.yml +60 -29
  29. data/features/cassettes/orgs/list/user.yml +87 -57
  30. data/features/cassettes/pagination/issues/list/first.yml +65 -33
  31. data/features/cassettes/pagination/issues/list/last.yml +66 -33
  32. data/features/cassettes/pagination/repos/commits/list.yml +32 -1
  33. data/features/cassettes/pagination/repos/commits/sha.yml +32 -1
  34. data/features/cassettes/pagination/repos/diff.yml +32 -1
  35. data/features/cassettes/pagination/repos/list.yml +32 -1
  36. data/features/cassettes/pagination/repos/per_page/first.yml +32 -1
  37. data/features/cassettes/pull_requests/get.yml +120 -0
  38. data/features/cassettes/pull_requests/list.yml +254 -0
  39. data/features/cassettes/repos/branches.yml +32 -1
  40. data/features/cassettes/repos/contents/archive.yml +95 -0
  41. data/features/cassettes/repos/contents/get.yml +226 -0
  42. data/features/cassettes/repos/contents/readme.yml +271 -0
  43. data/features/cassettes/repos/get.yml +61 -31
  44. data/features/cassettes/repos/languages.yml +61 -30
  45. data/features/cassettes/repos/list.yml +32 -1
  46. data/features/cassettes/repos/tags.yml +32 -1
  47. data/features/cassettes/search/email.yml +99 -0
  48. data/features/cassettes/search/issues.yml +180 -0
  49. data/features/cassettes/search/repos.yml +396 -0
  50. data/features/cassettes/search/users.yml +54 -0
  51. data/features/cassettes/users/emails/add.yml +61 -30
  52. data/features/cassettes/users/emails/all.yml +61 -30
  53. data/features/cassettes/users/get/oauth.yml +61 -0
  54. data/features/cassettes/users/get/user.yml +62 -0
  55. data/features/issues.feature +64 -0
  56. data/features/pull_requests.feature +27 -0
  57. data/features/repos/contents.feature +35 -0
  58. data/features/search.feature +48 -0
  59. data/features/users.feature +23 -0
  60. data/lib/github_api.rb +1 -0
  61. data/lib/github_api/api.rb +0 -15
  62. data/lib/github_api/client.rb +4 -0
  63. data/lib/github_api/constants.rb +4 -0
  64. data/lib/github_api/error.rb +1 -0
  65. data/lib/github_api/error/unknown_value.rb +18 -0
  66. data/lib/github_api/filter.rb +1 -0
  67. data/lib/github_api/gists.rb +2 -6
  68. data/lib/github_api/gists/comments.rb +2 -2
  69. data/lib/github_api/git_data/blobs.rb +1 -1
  70. data/lib/github_api/git_data/commits.rb +1 -1
  71. data/lib/github_api/git_data/references.rb +2 -2
  72. data/lib/github_api/git_data/tags.rb +1 -1
  73. data/lib/github_api/git_data/trees.rb +2 -3
  74. data/lib/github_api/issues.rb +6 -6
  75. data/lib/github_api/issues/comments.rb +2 -2
  76. data/lib/github_api/issues/labels.rb +2 -2
  77. data/lib/github_api/issues/milestones.rb +3 -3
  78. data/lib/github_api/orgs/teams.rb +4 -4
  79. data/lib/github_api/params_hash.rb +31 -0
  80. data/lib/github_api/pull_requests.rb +2 -2
  81. data/lib/github_api/pull_requests/comments.rb +2 -2
  82. data/lib/github_api/repos.rb +8 -10
  83. data/lib/github_api/repos/commits.rb +2 -2
  84. data/lib/github_api/repos/contents.rb +64 -0
  85. data/lib/github_api/repos/downloads.rb +1 -1
  86. data/lib/github_api/repos/hooks.rb +2 -2
  87. data/lib/github_api/repos/keys.rb +1 -1
  88. data/lib/github_api/result.rb +8 -0
  89. data/lib/github_api/search.rb +98 -0
  90. data/lib/github_api/users.rb +8 -6
  91. data/lib/github_api/users/emails.rb +2 -2
  92. data/lib/github_api/validations/format.rb +4 -3
  93. data/lib/github_api/validations/required.rb +5 -2
  94. data/lib/github_api/version.rb +2 -2
  95. data/spec/fixtures/repos/content.json +14 -0
  96. data/spec/fixtures/repos/readme.json +14 -0
  97. data/spec/fixtures/search/email.json +22 -0
  98. data/spec/fixtures/search/issues.json +23 -0
  99. data/spec/fixtures/search/repositories.json +29 -0
  100. data/spec/fixtures/search/users.json +24 -0
  101. data/spec/github/error/unknown_value_spec.rb +21 -0
  102. data/spec/github/repos/contents_spec.rb +65 -0
  103. data/spec/github/search_spec.rb +87 -0
  104. data/spec/github/users_spec.rb +7 -7
  105. data/spec/github/validations/format_spec.rb +6 -6
  106. data/spec/github/validations/required_spec.rb +3 -3
  107. metadata +69 -35
@@ -0,0 +1,22 @@
1
+ {
2
+ "user": {
3
+ "gravatar_id": "70889091349f7598bce9afa588034310",
4
+ "name": "Hirotaka Kawata",
5
+ "created_at": "2009-10-05T01:32:06Z",
6
+ "location": "Tsukuba, Ibaraki, Japan",
7
+ "public_repo_count": 8,
8
+ "followers": 10,
9
+ "language": "Python",
10
+ "fullname": "Hirotaka Kawata",
11
+ "username": "techno",
12
+ "id": "user-135050",
13
+ "repos": 8,
14
+ "type": "user",
15
+ "followers_count": 10,
16
+ "pushed": "2012-04-18T02:15:17.511Z",
17
+ "login": "techno",
18
+ "score": 4.2559967,
19
+ "record": null,
20
+ "created": "2009-10-05T01:32:06Z"
21
+ }
22
+ }
@@ -0,0 +1,23 @@
1
+ {
2
+ "issues": [
3
+ {
4
+ "gravatar_id": "4c3d600867886124a73f14a907b1a955",
5
+ "position": 10,
6
+ "number": 10,
7
+ "votes": 2,
8
+ "created_at": "2010-06-04T23:20:33-07:00",
9
+ "comments": 5,
10
+ "body": "Issue body goes here",
11
+ "title": "This is is the issue title",
12
+ "updated_at": "2010-06-04T23:20:33-07:00",
13
+ "html_url": "https => //github.com/pengwynn/linkedin/issues/10",
14
+ "user": "ckarbass",
15
+ "labels": [
16
+ "api",
17
+ "feature request",
18
+ "investigation"
19
+ ],
20
+ "state": "open"
21
+ }
22
+ ]
23
+ }
@@ -0,0 +1,29 @@
1
+ {
2
+ "repositories": [
3
+ {
4
+ "type": "repo",
5
+ "created": "2011-09-05T11:07:54-07:00",
6
+ "watchers": 2913,
7
+ "has_downloads": true,
8
+ "username": "mathiasbynens",
9
+ "homepage": "http://mths.be/dotfiles",
10
+ "url": "https://github.com/mathiasbynens/dotfiles",
11
+ "fork": false,
12
+ "has_issues": true,
13
+ "has_wiki": false,
14
+ "forks": 520,
15
+ "size": 192,
16
+ "private": false,
17
+ "followers": 2913,
18
+ "name": "dotfiles",
19
+ "owner": "mathiasbynens",
20
+ "open_issues": 12,
21
+ "pushed_at": "2012-06-05T03:37:13-07:00",
22
+ "score": 3.289718,
23
+ "pushed": "2012-06-05T03:37:13-07:00",
24
+ "description": "sensible hacker defaults for OS X",
25
+ "language": "VimL",
26
+ "created_at": "2011-09-05T11:07:54-07:00"
27
+ }
28
+ ]
29
+ }
@@ -0,0 +1,24 @@
1
+ {
2
+ "users": [
3
+ {
4
+ "gravatar_id": "70889091349f7598bce9afa588034310",
5
+ "name": "Hirotaka Kawata",
6
+ "created_at": "2009-10-05T01:32:06Z",
7
+ "location": "Tsukuba, Ibaraki, Japan",
8
+ "public_repo_count": 8,
9
+ "followers": 10,
10
+ "language": "Python",
11
+ "fullname": "Hirotaka Kawata",
12
+ "username": "techno",
13
+ "id": "user-135050",
14
+ "repos": 8,
15
+ "type": "user",
16
+ "followers_count": 10,
17
+ "pushed": "2012-04-18T02:15:17.511Z",
18
+ "login": "techno",
19
+ "score": 4.2559967,
20
+ "record": null,
21
+ "created": "2009-10-05T01:32:06Z"
22
+ }
23
+ ]
24
+ }
@@ -0,0 +1,21 @@
1
+ # encoding: utf-8
2
+
3
+ require 'spec_helper'
4
+
5
+ describe Github::Error::UnknownValue do
6
+ describe '#message' do
7
+ let(:error) { described_class.new(:state, 'open', "closed, deleted") }
8
+
9
+ it 'contains the problem in the message' do
10
+ error.message.should include "Wrong value of 'open' for the parameter: state provided for this request"
11
+ end
12
+
13
+ it 'contains the summary in the message' do
14
+ error.message.should include "Github gem checks the request parameters passed to ensure that github api is not hit unnecessairly and fails fast."
15
+ end
16
+
17
+ it 'contains the resolution in the message' do
18
+ error.message.should include "Permitted values are: closed, deleted, make sure these are the ones you are using"
19
+ end
20
+ end
21
+ end # Github::Error::UnkownValue
@@ -0,0 +1,65 @@
1
+ # encoding: utf-8
2
+
3
+ require 'spec_helper'
4
+
5
+ describe Github::Repos::Contents do
6
+ let(:github) { Github.new }
7
+ let(:user) { 'octokit' }
8
+ let(:repo) { 'github' }
9
+
10
+ after { reset_authentication_for(github) }
11
+
12
+ context "#readme" do
13
+ before do
14
+ stub_get("/repos/#{user}/#{repo}/readme").
15
+ to_return(:body => fixture('repos/readme.json'), :status => 200,
16
+ :headers => {:content_type => "application/json; charset=utf-8"})
17
+ end
18
+
19
+ it "should get the resources" do
20
+ github.repos.contents.readme user, repo
21
+ a_get("/repos/#{user}/#{repo}/readme").should have_been_made
22
+ end
23
+
24
+ it "should get readme information" do
25
+ readme= github.repos.contents.readme user, repo
26
+ readme.name.should == 'README.md'
27
+ end
28
+ end
29
+
30
+ context "#get" do
31
+ let(:path) { 'README.md' }
32
+
33
+ before do
34
+ stub_get("/repos/#{user}/#{repo}/contents/#{path}").
35
+ to_return(:body => fixture('repos/content.json'), :status => 200,
36
+ :headers => {:content_type => "application/json; charset=utf-8"})
37
+ end
38
+
39
+ it "should get the resources" do
40
+ github.repos.contents.get user, repo, path
41
+ a_get("/repos/#{user}/#{repo}/contents/#{path}").should have_been_made
42
+ end
43
+
44
+ it "should get repository information" do
45
+ content = github.repos.contents.get user, repo, path
46
+ content.name.should == 'README.md'
47
+ end
48
+ end
49
+
50
+ context "#users" do
51
+ let(:archive_format) { 'tarball' }
52
+ let(:ref) { 'master' }
53
+
54
+ before do
55
+ stub_get("/repos/#{user}/#{repo}/#{archive_format}/#{ref}").
56
+ to_return(:body => '', :status => 302)
57
+ end
58
+
59
+ it "should get the resources" do
60
+ github.repos.contents.archive user, repo, :archive_format => archive_format, :ref => ref
61
+ a_get("/repos/#{user}/#{repo}/#{archive_format}/#{ref}").should have_been_made
62
+ end
63
+ end
64
+
65
+ end # Github::Repos::Contents
@@ -0,0 +1,87 @@
1
+ # encoding: utf-8
2
+
3
+ require 'spec_helper'
4
+
5
+ describe Github::Search do
6
+ let(:github) { Github.new }
7
+ let(:keyword) { 'api' }
8
+
9
+ after { reset_authentication_for(github) }
10
+
11
+ context "#issues" do
12
+ let(:owner) { 'peter-murach' }
13
+ let(:repo) { 'github' }
14
+ let(:state) { 'closed' }
15
+
16
+ before do
17
+ stub_get("/legacy/issues/search/#{owner}/#{repo}/#{state}/#{keyword}").
18
+ to_return(:body => fixture('search/issues.json'), :status => 200,
19
+ :headers => {:content_type => "application/json; charset=utf-8"})
20
+ end
21
+
22
+ it "should get the resources" do
23
+ github.search.issues :owner => owner, :repo => repo, :state => state, :keyword => keyword
24
+ a_get("/legacy/issues/search/#{owner}/#{repo}/#{state}/#{keyword}").should have_been_made
25
+ end
26
+
27
+ it "should get issue information" do
28
+ issues = github.search.issues :owner => owner, :repo => repo, :state => state, :keyword => keyword
29
+ issues.issues.first.user.should == 'ckarbass'
30
+ end
31
+ end
32
+
33
+ context "#repositories" do
34
+ before do
35
+ stub_get("/legacy/repos/search/#{keyword}").
36
+ to_return(:body => fixture('search/repositories.json'), :status => 200,
37
+ :headers => {:content_type => "application/json; charset=utf-8"})
38
+ end
39
+
40
+ it "should get the resources" do
41
+ github.search.repos :keyword => keyword
42
+ a_get("/legacy/repos/search/#{keyword}").should have_been_made
43
+ end
44
+
45
+ it "should get repository information" do
46
+ repos = github.search.repos :keyword => keyword
47
+ repos.repositories.first.username.should == 'mathiasbynens'
48
+ end
49
+ end
50
+
51
+ context "#users" do
52
+ before do
53
+ stub_get("/legacy/user/search/#{keyword}").
54
+ to_return(:body => fixture('search/users.json'), :status => 200,
55
+ :headers => {:content_type => "application/json; charset=utf-8"})
56
+ end
57
+
58
+ it "should get the resources" do
59
+ github.search.users :keyword => keyword
60
+ a_get("/legacy/user/search/#{keyword}").should have_been_made
61
+ end
62
+
63
+ it "should get user information" do
64
+ users = github.search.users :keyword => keyword
65
+ users.users.first.username.should == 'techno'
66
+ end
67
+ end
68
+
69
+ context "#email" do
70
+ before do
71
+ stub_get("/legacy/user/email/#{keyword}").
72
+ to_return(:body => fixture('search/email.json'), :status => 200,
73
+ :headers => {:content_type => "application/json; charset=utf-8"})
74
+ end
75
+
76
+ it "should get the resources" do
77
+ github.search.email :email => keyword
78
+ a_get("/legacy/user/email/#{keyword}").should have_been_made
79
+ end
80
+
81
+ it "should get user information" do
82
+ user = github.search.email :email => keyword
83
+ user.user.username.should == 'techno'
84
+ end
85
+ end
86
+
87
+ end # Github::Search
@@ -18,28 +18,28 @@ describe Github::Users do
18
18
  end
19
19
 
20
20
  it "should get the resources" do
21
- github.users.get user
21
+ github.users.get :user => user
22
22
  a_get("/users/#{user}").should have_been_made
23
23
  end
24
24
 
25
25
  it "should return resource" do
26
- user_resource = github.users.get user
26
+ user_resource = github.users.get :user => user
27
27
  user_resource.should be_a Hash
28
28
  end
29
29
 
30
30
  it "should be a mash type" do
31
- user_resource = github.users.get user
31
+ user_resource = github.users.get :user => user
32
32
  user_resource.should be_a Hashie::Mash
33
33
  end
34
34
 
35
35
  it "should get org information" do
36
- user_resource = github.users.get user
36
+ user_resource = github.users.get :user => user
37
37
  user_resource.login.should == 'octocat'
38
38
  end
39
39
 
40
40
  it "should yield to a block" do
41
- github.users.should_receive(:get).with(user).and_yield('web')
42
- github.users.get(user) { |param| 'web' }
41
+ github.users.should_receive(:get).with(:user => user).and_yield('web')
42
+ github.users.get(:user => user) { |param| 'web' }
43
43
  end
44
44
  end
45
45
 
@@ -66,7 +66,7 @@ describe Github::Users do
66
66
 
67
67
  it "should return 404 with a message 'Not Found'" do
68
68
  expect {
69
- github.users.get user
69
+ github.users.get :user => user
70
70
  }.to raise_error(Github::Error::NotFound)
71
71
  end
72
72
  end
@@ -17,25 +17,25 @@ describe Github::Validations::Format do
17
17
  it 'fails to accept unkown value for a given parameter key' do
18
18
  actual = { 'param_a' => 'x' }
19
19
  expect {
20
- validator._validate_params_values(permitted, actual)
21
- }.to raise_error(ArgumentError)
20
+ validator.assert_valid_values(permitted, actual)
21
+ }.to raise_error(Github::Error::UnknownValue)
22
22
  end
23
23
 
24
24
  it 'accepts known value for a given parameter key' do
25
25
  actual = { 'param_a' => 'a'}
26
- validator._validate_params_values(permitted, actual)
26
+ validator.assert_valid_values(permitted, actual)
27
27
  end
28
28
 
29
29
  it 'fails to match regex value for a given parameter key' do
30
30
  actual = { 'param_b' => 'xgithub' }
31
31
  expect {
32
- validator._validate_params_values(permitted, actual)
33
- }.to raise_error(ArgumentError)
32
+ validator.assert_valid_values(permitted, actual)
33
+ }.to raise_error(Github::Error::UnknownValue)
34
34
  end
35
35
 
36
36
  it 'matches regex value for a given parameter key' do
37
37
  actual = { 'param_b' => 'github'}
38
- validator._validate_params_values(permitted, actual)
38
+ validator.assert_valid_values(permitted, actual)
39
39
  end
40
40
  end
41
41
 
@@ -9,19 +9,19 @@ describe Github::Validations::Required do
9
9
  klaz = Class.new.extend(described_class)
10
10
  }
11
11
 
12
- context '#_validate_inputs' do
12
+ context '#assert_required_keys' do
13
13
  let(:required) { ['param_a', 'param_c'] }
14
14
  let(:provided) { { 'param_a' => true, 'param_c' => true } }
15
15
 
16
16
  it 'detect missing parameter' do
17
17
  expect {
18
- validator._validate_inputs(required, provided.except('param_c')).
18
+ validator.assert_required_keys(required, provided.except('param_c')).
19
19
  should be_false
20
20
  }.to raise_error(Github::Error::RequiredParams)
21
21
  end
22
22
 
23
23
  it 'asserts correct required parameters' do
24
- validator._validate_inputs(required, provided).should be_true
24
+ validator.assert_required_keys(required, provided).should be_true
25
25
  end
26
26
  end
27
27
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: github_api
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.4
4
+ version: 0.6.0
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,11 +9,11 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-06-09 00:00:00.000000000Z
12
+ date: 2012-06-12 00:00:00.000000000Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: hashie
16
- requirement: &2154258300 !ruby/object:Gem::Requirement
16
+ requirement: &2153407400 !ruby/object:Gem::Requirement
17
17
  none: false
18
18
  requirements:
19
19
  - - ~>
@@ -21,10 +21,10 @@ dependencies:
21
21
  version: 1.2.0
22
22
  type: :runtime
23
23
  prerelease: false
24
- version_requirements: *2154258300
24
+ version_requirements: *2153407400
25
25
  - !ruby/object:Gem::Dependency
26
26
  name: faraday
27
- requirement: &2154257800 !ruby/object:Gem::Requirement
27
+ requirement: &2153406900 !ruby/object:Gem::Requirement
28
28
  none: false
29
29
  requirements:
30
30
  - - ~>
@@ -32,10 +32,10 @@ dependencies:
32
32
  version: 0.8.0
33
33
  type: :runtime
34
34
  prerelease: false
35
- version_requirements: *2154257800
35
+ version_requirements: *2153406900
36
36
  - !ruby/object:Gem::Dependency
37
37
  name: multi_json
38
- requirement: &2154257340 !ruby/object:Gem::Requirement
38
+ requirement: &2153406420 !ruby/object:Gem::Requirement
39
39
  none: false
40
40
  requirements:
41
41
  - - ~>
@@ -43,10 +43,10 @@ dependencies:
43
43
  version: '1.3'
44
44
  type: :runtime
45
45
  prerelease: false
46
- version_requirements: *2154257340
46
+ version_requirements: *2153406420
47
47
  - !ruby/object:Gem::Dependency
48
48
  name: oauth2
49
- requirement: &2154256880 !ruby/object:Gem::Requirement
49
+ requirement: &2153392320 !ruby/object:Gem::Requirement
50
50
  none: false
51
51
  requirements:
52
52
  - - ~>
@@ -54,10 +54,10 @@ dependencies:
54
54
  version: '0.7'
55
55
  type: :runtime
56
56
  prerelease: false
57
- version_requirements: *2154256880
57
+ version_requirements: *2153392320
58
58
  - !ruby/object:Gem::Dependency
59
59
  name: nokogiri
60
- requirement: &2154256420 !ruby/object:Gem::Requirement
60
+ requirement: &2153391800 !ruby/object:Gem::Requirement
61
61
  none: false
62
62
  requirements:
63
63
  - - ~>
@@ -65,10 +65,10 @@ dependencies:
65
65
  version: 1.5.2
66
66
  type: :runtime
67
67
  prerelease: false
68
- version_requirements: *2154256420
68
+ version_requirements: *2153391800
69
69
  - !ruby/object:Gem::Dependency
70
70
  name: rspec
71
- requirement: &2154272320 !ruby/object:Gem::Requirement
71
+ requirement: &2153391320 !ruby/object:Gem::Requirement
72
72
  none: false
73
73
  requirements:
74
74
  - - ! '>='
@@ -76,10 +76,10 @@ dependencies:
76
76
  version: '0'
77
77
  type: :development
78
78
  prerelease: false
79
- version_requirements: *2154272320
79
+ version_requirements: *2153391320
80
80
  - !ruby/object:Gem::Dependency
81
81
  name: cucumber
82
- requirement: &2154271860 !ruby/object:Gem::Requirement
82
+ requirement: &2153390860 !ruby/object:Gem::Requirement
83
83
  none: false
84
84
  requirements:
85
85
  - - ! '>='
@@ -87,10 +87,10 @@ dependencies:
87
87
  version: '0'
88
88
  type: :development
89
89
  prerelease: false
90
- version_requirements: *2154271860
90
+ version_requirements: *2153390860
91
91
  - !ruby/object:Gem::Dependency
92
92
  name: yajl-ruby
93
- requirement: &2154271400 !ruby/object:Gem::Requirement
93
+ requirement: &2153390380 !ruby/object:Gem::Requirement
94
94
  none: false
95
95
  requirements:
96
96
  - - ~>
@@ -98,10 +98,10 @@ dependencies:
98
98
  version: 1.1.0
99
99
  type: :development
100
100
  prerelease: false
101
- version_requirements: *2154271400
101
+ version_requirements: *2153390380
102
102
  - !ruby/object:Gem::Dependency
103
103
  name: webmock
104
- requirement: &2154270940 !ruby/object:Gem::Requirement
104
+ requirement: &2153389860 !ruby/object:Gem::Requirement
105
105
  none: false
106
106
  requirements:
107
107
  - - ~>
@@ -109,10 +109,10 @@ dependencies:
109
109
  version: 1.8.0
110
110
  type: :development
111
111
  prerelease: false
112
- version_requirements: *2154270940
112
+ version_requirements: *2153389860
113
113
  - !ruby/object:Gem::Dependency
114
114
  name: vcr
115
- requirement: &2154270480 !ruby/object:Gem::Requirement
115
+ requirement: &2153389400 !ruby/object:Gem::Requirement
116
116
  none: false
117
117
  requirements:
118
118
  - - ~>
@@ -120,10 +120,10 @@ dependencies:
120
120
  version: 2.2.0
121
121
  type: :development
122
122
  prerelease: false
123
- version_requirements: *2154270480
123
+ version_requirements: *2153389400
124
124
  - !ruby/object:Gem::Dependency
125
125
  name: simplecov
126
- requirement: &2154270020 !ruby/object:Gem::Requirement
126
+ requirement: &2153388880 !ruby/object:Gem::Requirement
127
127
  none: false
128
128
  requirements:
129
129
  - - ~>
@@ -131,10 +131,10 @@ dependencies:
131
131
  version: 0.6.1
132
132
  type: :development
133
133
  prerelease: false
134
- version_requirements: *2154270020
134
+ version_requirements: *2153388880
135
135
  - !ruby/object:Gem::Dependency
136
136
  name: guard
137
- requirement: &2154269640 !ruby/object:Gem::Requirement
137
+ requirement: &2153388500 !ruby/object:Gem::Requirement
138
138
  none: false
139
139
  requirements:
140
140
  - - ! '>='
@@ -142,10 +142,10 @@ dependencies:
142
142
  version: '0'
143
143
  type: :development
144
144
  prerelease: false
145
- version_requirements: *2154269640
145
+ version_requirements: *2153388500
146
146
  - !ruby/object:Gem::Dependency
147
147
  name: guard-rspec
148
- requirement: &2154269180 !ruby/object:Gem::Requirement
148
+ requirement: &2153388020 !ruby/object:Gem::Requirement
149
149
  none: false
150
150
  requirements:
151
151
  - - ! '>='
@@ -153,10 +153,10 @@ dependencies:
153
153
  version: '0'
154
154
  type: :development
155
155
  prerelease: false
156
- version_requirements: *2154269180
156
+ version_requirements: *2153388020
157
157
  - !ruby/object:Gem::Dependency
158
158
  name: guard-cucumber
159
- requirement: &2154268760 !ruby/object:Gem::Requirement
159
+ requirement: &2153387560 !ruby/object:Gem::Requirement
160
160
  none: false
161
161
  requirements:
162
162
  - - ! '>='
@@ -164,10 +164,10 @@ dependencies:
164
164
  version: '0'
165
165
  type: :development
166
166
  prerelease: false
167
- version_requirements: *2154268760
167
+ version_requirements: *2153387560
168
168
  - !ruby/object:Gem::Dependency
169
169
  name: rake
170
- requirement: &2154268340 !ruby/object:Gem::Requirement
170
+ requirement: &2153387140 !ruby/object:Gem::Requirement
171
171
  none: false
172
172
  requirements:
173
173
  - - ! '>='
@@ -175,10 +175,10 @@ dependencies:
175
175
  version: '0'
176
176
  type: :development
177
177
  prerelease: false
178
- version_requirements: *2154268340
178
+ version_requirements: *2153387140
179
179
  - !ruby/object:Gem::Dependency
180
180
  name: bundler
181
- requirement: &2154267920 !ruby/object:Gem::Requirement
181
+ requirement: &2153386680 !ruby/object:Gem::Requirement
182
182
  none: false
183
183
  requirements:
184
184
  - - ! '>='
@@ -186,7 +186,7 @@ dependencies:
186
186
  version: '0'
187
187
  type: :development
188
188
  prerelease: false
189
- version_requirements: *2154267920
189
+ version_requirements: *2153386680
190
190
  description: ! ' Ruby wrapper that supports all of the GitHub API v3 methods(nearly
191
191
  200). It''s build in a modular way, that is, you can either instantiate the whole
192
192
  api wrapper Github.new or use parts of it e.i. Github::Repos.new if working solely
@@ -219,6 +219,11 @@ files:
219
219
  - features/cassettes/git_data/references/all.yml
220
220
  - features/cassettes/git_data/references/all_tags.yml
221
221
  - features/cassettes/git_data/references/one.yml
222
+ - features/cassettes/issues/create.yml
223
+ - features/cassettes/issues/edit.yml
224
+ - features/cassettes/issues/get.yml
225
+ - features/cassettes/issues/list/repo.yml
226
+ - features/cassettes/issues/list/user.yml
222
227
  - features/cassettes/orgs/get.yml
223
228
  - features/cassettes/orgs/list/oauth_user.yml
224
229
  - features/cassettes/orgs/list/user.yml
@@ -236,27 +241,42 @@ files:
236
241
  - features/cassettes/pagination/repos/list.yml
237
242
  - features/cassettes/pagination/repos/per_page/each_page.yml
238
243
  - features/cassettes/pagination/repos/per_page/first.yml
244
+ - features/cassettes/pull_requests/get.yml
245
+ - features/cassettes/pull_requests/list.yml
239
246
  - features/cassettes/repos/branches.yml
247
+ - features/cassettes/repos/contents/archive.yml
248
+ - features/cassettes/repos/contents/get.yml
249
+ - features/cassettes/repos/contents/readme.yml
240
250
  - features/cassettes/repos/create.yml
241
251
  - features/cassettes/repos/get.yml
242
252
  - features/cassettes/repos/languages.yml
243
253
  - features/cassettes/repos/list.yml
244
254
  - features/cassettes/repos/tags.yml
245
255
  - features/cassettes/repos/teams.yml
256
+ - features/cassettes/search/email.yml
257
+ - features/cassettes/search/issues.yml
258
+ - features/cassettes/search/repos.yml
259
+ - features/cassettes/search/users.yml
246
260
  - features/cassettes/users/emails/add.yml
247
261
  - features/cassettes/users/emails/all.yml
248
262
  - features/cassettes/users/emails/delete.yml
263
+ - features/cassettes/users/get/oauth.yml
264
+ - features/cassettes/users/get/user.yml
249
265
  - features/error_codes.feature
250
266
  - features/events.feature
251
267
  - features/gists/comments.feature
252
268
  - features/gists.feature
253
269
  - features/git_data/references.feature
254
270
  - features/github_api.feature
271
+ - features/issues.feature
255
272
  - features/options.feature
256
273
  - features/orgs.feature
257
274
  - features/pagination.feature
275
+ - features/pull_requests.feature
258
276
  - features/README.rdoc
277
+ - features/repos/contents.feature
259
278
  - features/repos.feature
279
+ - features/search.feature
260
280
  - features/settings.yml
261
281
  - features/settings.yml.sample
262
282
  - features/step_definitions/common_steps.rb
@@ -266,6 +286,7 @@ files:
266
286
  - features/support/settings.rb
267
287
  - features/support/vcr.rb
268
288
  - features/users/emails.feature
289
+ - features/users.feature
269
290
  - lib/github_api/api/actions.rb
270
291
  - lib/github_api/api.rb
271
292
  - lib/github_api/api_factory.rb
@@ -290,6 +311,7 @@ files:
290
311
  - lib/github_api/error/service_error.rb
291
312
  - lib/github_api/error/service_unavailable.rb
292
313
  - lib/github_api/error/unauthorized.rb
314
+ - lib/github_api/error/unknown_value.rb
293
315
  - lib/github_api/error/unprocessable_entity.rb
294
316
  - lib/github_api/error/validations.rb
295
317
  - lib/github_api/error.rb
@@ -316,11 +338,13 @@ files:
316
338
  - lib/github_api/page_links.rb
317
339
  - lib/github_api/page_uri_processor.rb
318
340
  - lib/github_api/paged_request.rb
341
+ - lib/github_api/params_hash.rb
319
342
  - lib/github_api/pull_requests/comments.rb
320
343
  - lib/github_api/pull_requests.rb
321
344
  - lib/github_api/ratelimit_status.rb
322
345
  - lib/github_api/repos/collaborators.rb
323
346
  - lib/github_api/repos/commits.rb
347
+ - lib/github_api/repos/contents.rb
324
348
  - lib/github_api/repos/downloads.rb
325
349
  - lib/github_api/repos/forks.rb
326
350
  - lib/github_api/repos/hooks.rb
@@ -341,6 +365,7 @@ files:
341
365
  - lib/github_api/response.rb
342
366
  - lib/github_api/result.rb
343
367
  - lib/github_api/s3_uploader.rb
368
+ - lib/github_api/search.rb
344
369
  - lib/github_api/users/emails.rb
345
370
  - lib/github_api/users/followers.rb
346
371
  - lib/github_api/users/keys.rb
@@ -399,6 +424,7 @@ files:
399
424
  - spec/fixtures/repos/commit_comments.json
400
425
  - spec/fixtures/repos/commit_comparison.json
401
426
  - spec/fixtures/repos/commits.json
427
+ - spec/fixtures/repos/content.json
402
428
  - spec/fixtures/repos/contributors.json
403
429
  - spec/fixtures/repos/download.json
404
430
  - spec/fixtures/repos/download_s3.json
@@ -410,6 +436,7 @@ files:
410
436
  - spec/fixtures/repos/key.json
411
437
  - spec/fixtures/repos/keys.json
412
438
  - spec/fixtures/repos/languages.json
439
+ - spec/fixtures/repos/readme.json
413
440
  - spec/fixtures/repos/repo.json
414
441
  - spec/fixtures/repos/repo_comments.json
415
442
  - spec/fixtures/repos/repos.json
@@ -417,6 +444,10 @@ files:
417
444
  - spec/fixtures/repos/teams.json
418
445
  - spec/fixtures/repos/watched.json
419
446
  - spec/fixtures/repos/watchers.json
447
+ - spec/fixtures/search/email.json
448
+ - spec/fixtures/search/issues.json
449
+ - spec/fixtures/search/repositories.json
450
+ - spec/fixtures/search/users.json
420
451
  - spec/fixtures/users/emails.json
421
452
  - spec/fixtures/users/followers.json
422
453
  - spec/fixtures/users/key.json
@@ -432,6 +463,7 @@ files:
432
463
  - spec/github/error/client_error_spec.rb
433
464
  - spec/github/error/invalid_options_spec.rb
434
465
  - spec/github/error/required_params_spec.rb
466
+ - spec/github/error/unknown_value_spec.rb
435
467
  - spec/github/events_spec.rb
436
468
  - spec/github/filter_spec.rb
437
469
  - spec/github/gists/comments_spec.rb
@@ -458,6 +490,7 @@ files:
458
490
  - spec/github/pull_requests_spec.rb
459
491
  - spec/github/repos/collaborators_spec.rb
460
492
  - spec/github/repos/commits_spec.rb
493
+ - spec/github/repos/contents_spec.rb
461
494
  - spec/github/repos/downloads_spec.rb
462
495
  - spec/github/repos/forks_spec.rb
463
496
  - spec/github/repos/hooks_spec.rb
@@ -471,6 +504,7 @@ files:
471
504
  - spec/github/response/helpers_spec.rb
472
505
  - spec/github/result_spec.rb
473
506
  - spec/github/s3_uploader_spec.rb
507
+ - spec/github/search_spec.rb
474
508
  - spec/github/users/emails_spec.rb
475
509
  - spec/github/users/followers_spec.rb
476
510
  - spec/github/users/keys_spec.rb
@@ -492,7 +526,7 @@ files:
492
526
  homepage: https://github.com/peter-murach/github
493
527
  licenses: []
494
528
  post_install_message: ! "\n--------------------------------------------------------------------------------\nThank
495
- you for installing github_api-0.5.4.\n\n*NOTE*: Version 0.5.0 introduces breaking
529
+ you for installing github_api-0.6.0.\n\n*NOTE*: Version 0.5.0 introduces breaking
496
530
  changes to the way github api is queried.\nThe interface has been rewritten to be
497
531
  more consistent with REST verbs that\ninteract with GitHub hypermedia resources.
498
532
  Thus, to list resources 'list' or 'all'\nverbs are used, to retrieve individual