omniauth-github 1.2.3 → 1.3.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 5c212a3464f953d08d08e5d841f00e4b385e9325
4
- data.tar.gz: d5fb04f3cd39d2187f9e34ca28c73211f7cf6e39
3
+ metadata.gz: 7360551f98f08e0dc6b099cb8244f1c228be89b9
4
+ data.tar.gz: aeee13d4e028e0f6d55ecc2b395bbe13d129055f
5
5
  SHA512:
6
- metadata.gz: 605324691f4ce74dbbde321b9e2f9ef3b2f2811a832fed1c87667c83f92c42a9c4a38ddba292727d6f772647afa47dbb534608a192d3df015d5a13fd765f6249
7
- data.tar.gz: 6782f5a3e26b86ebc756a759e84c0fa315d5b323922a1251a38d63e8613f264e4dc20b77b3460731c0995055778402bdc7cab56f46ddda254987b5f1ff8d35ca
6
+ metadata.gz: d0dc0f3cf76e07f851edfd9689302dadc618e98a12b03420f62aa836fef5ce14a7c458bf2d0d30d6c7c66ce332ad65ac610ff636532f7821611844f2db67235f
7
+ data.tar.gz: fca276a62cb23009a282ecbeb9e8b18e50a9b5048a71665742203514d55de636c6220b4aa8af8aabc76a14d3fe3c7be0dd172208d15829cc7741ba17fa52e2ee
@@ -1,5 +1,5 @@
1
1
  module OmniAuth
2
2
  module GitHub
3
- VERSION = "1.2.3"
3
+ VERSION = "1.3.0"
4
4
  end
5
5
  end
@@ -69,6 +69,10 @@ module OmniAuth
69
69
  scopes = options['scope'].split(',')
70
70
  (scopes & email_scopes).any?
71
71
  end
72
+
73
+ def callback_url
74
+ full_host + script_name + callback_path
75
+ end
72
76
  end
73
77
  end
74
78
  end
@@ -149,4 +149,13 @@ describe OmniAuth::Strategies::GitHub do
149
149
  expect(subject.info['urls']['GitHub']).to eq('http://enterprise/me')
150
150
  end
151
151
  end
152
+
153
+ describe '#callback_url' do
154
+ it 'is a combination of host, script name, and callback path' do
155
+ allow(subject).to receive(:full_host).and_return('https://example.com')
156
+ allow(subject).to receive(:script_name).and_return('/sub_uri')
157
+
158
+ expect(subject.callback_url).to eq('https://example.com/sub_uri/auth/github/callback')
159
+ end
160
+ end
152
161
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: omniauth-github
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.3
4
+ version: 1.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Michael Bleigh
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-02-18 00:00:00.000000000 Z
11
+ date: 2017-05-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: omniauth
@@ -140,7 +140,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
140
140
  version: '0'
141
141
  requirements: []
142
142
  rubyforge_project:
143
- rubygems_version: 2.6.10
143
+ rubygems_version: 2.6.11
144
144
  signing_key:
145
145
  specification_version: 4
146
146
  summary: Official OmniAuth strategy for GitHub.