omniauth-tanmer 1.0.3 → 1.0.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile +6 -0
- data/README.md +1 -1
- data/lib/omniauth/strategies/tanmer.rb +2 -2
- data/lib/omniauth-tanmer/version.rb +1 -1
- data/omniauth-tanmer.gemspec +0 -5
- data/spec/omniauth/strategies/tanmer_spec.rb +2 -2
- metadata +2 -72
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 64de0273582add790e8fec1a2ba3f49707a7ea30
|
4
|
+
data.tar.gz: 596f1181c30179361e9bf086e39a8718b7229843
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 06a34922c12807ce1fe9bbdb7cbd955d32a34e0a436a7be93a9a9af9de02272f8995ff15656aa3928fd324a3565f37447be75134b36baba0f41f57adc76cc58e
|
7
|
+
data.tar.gz: ec58268a74f950788b1ff297f47c03ba5979e452d12526dbb35d18a7382da0bf757c66c237bdc4997270ca34e458c47e2af437b6a4f4a1ad81596c4d56fad24c
|
data/Gemfile
CHANGED
data/README.md
CHANGED
@@ -5,7 +5,7 @@ module OmniAuth
|
|
5
5
|
class Tanmer < OmniAuth::Strategies::OAuth2
|
6
6
|
|
7
7
|
option :client_options, {
|
8
|
-
site: 'https://
|
8
|
+
site: 'https://account.tanmer.com',
|
9
9
|
authorize_url: '/oauth/authorize',
|
10
10
|
token_url: '/oauth/token'
|
11
11
|
}
|
@@ -27,7 +27,7 @@ module OmniAuth
|
|
27
27
|
end
|
28
28
|
|
29
29
|
def raw_info
|
30
|
-
@raw_info ||= access_token.get('/api/v1/
|
30
|
+
@raw_info ||= access_token.get('/api/v1/users/profile').parsed
|
31
31
|
end
|
32
32
|
|
33
33
|
private
|
data/omniauth-tanmer.gemspec
CHANGED
@@ -19,9 +19,4 @@ Gem::Specification.new do |gem|
|
|
19
19
|
|
20
20
|
gem.add_dependency 'omniauth', '~> 1.0'
|
21
21
|
gem.add_dependency 'omniauth-oauth2', '~> 1.0'
|
22
|
-
gem.add_development_dependency 'rspec', '~> 3.1'
|
23
|
-
gem.add_development_dependency 'rspec-its', '~> 1.0'
|
24
|
-
gem.add_development_dependency 'rack-test'
|
25
|
-
gem.add_development_dependency 'simplecov'
|
26
|
-
gem.add_development_dependency 'webmock'
|
27
22
|
end
|
@@ -32,7 +32,7 @@ describe OmniAuth::Strategies::Tanmer do
|
|
32
32
|
context 'with defaults' do
|
33
33
|
subject { tanmer_service.options.client_options }
|
34
34
|
|
35
|
-
its(:site) { is_expected.to eq 'https://
|
35
|
+
its(:site) { is_expected.to eq 'https://account.tanmer.com' }
|
36
36
|
its(:authorize_url) { is_expected.to eq '/oauth/authorize' }
|
37
37
|
its(:token_url) { is_expected.to eq '/oauth/token' }
|
38
38
|
end
|
@@ -60,7 +60,7 @@ describe OmniAuth::Strategies::Tanmer do
|
|
60
60
|
|
61
61
|
describe '#raw_info' do
|
62
62
|
it 'sent request to current user endpoint' do
|
63
|
-
expect(access_token).to receive(:get).with('/api/v1/
|
63
|
+
expect(access_token).to receive(:get).with('/api/v1/users/profile').and_return(response)
|
64
64
|
expect(subject.raw_info).to eq(parsed_response)
|
65
65
|
end
|
66
66
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: omniauth-tanmer
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- xiaohui
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-
|
11
|
+
date: 2017-10-16 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: omniauth
|
@@ -38,76 +38,6 @@ dependencies:
|
|
38
38
|
- - "~>"
|
39
39
|
- !ruby/object:Gem::Version
|
40
40
|
version: '1.0'
|
41
|
-
- !ruby/object:Gem::Dependency
|
42
|
-
name: rspec
|
43
|
-
requirement: !ruby/object:Gem::Requirement
|
44
|
-
requirements:
|
45
|
-
- - "~>"
|
46
|
-
- !ruby/object:Gem::Version
|
47
|
-
version: '3.1'
|
48
|
-
type: :development
|
49
|
-
prerelease: false
|
50
|
-
version_requirements: !ruby/object:Gem::Requirement
|
51
|
-
requirements:
|
52
|
-
- - "~>"
|
53
|
-
- !ruby/object:Gem::Version
|
54
|
-
version: '3.1'
|
55
|
-
- !ruby/object:Gem::Dependency
|
56
|
-
name: rspec-its
|
57
|
-
requirement: !ruby/object:Gem::Requirement
|
58
|
-
requirements:
|
59
|
-
- - "~>"
|
60
|
-
- !ruby/object:Gem::Version
|
61
|
-
version: '1.0'
|
62
|
-
type: :development
|
63
|
-
prerelease: false
|
64
|
-
version_requirements: !ruby/object:Gem::Requirement
|
65
|
-
requirements:
|
66
|
-
- - "~>"
|
67
|
-
- !ruby/object:Gem::Version
|
68
|
-
version: '1.0'
|
69
|
-
- !ruby/object:Gem::Dependency
|
70
|
-
name: rack-test
|
71
|
-
requirement: !ruby/object:Gem::Requirement
|
72
|
-
requirements:
|
73
|
-
- - ">="
|
74
|
-
- !ruby/object:Gem::Version
|
75
|
-
version: '0'
|
76
|
-
type: :development
|
77
|
-
prerelease: false
|
78
|
-
version_requirements: !ruby/object:Gem::Requirement
|
79
|
-
requirements:
|
80
|
-
- - ">="
|
81
|
-
- !ruby/object:Gem::Version
|
82
|
-
version: '0'
|
83
|
-
- !ruby/object:Gem::Dependency
|
84
|
-
name: simplecov
|
85
|
-
requirement: !ruby/object:Gem::Requirement
|
86
|
-
requirements:
|
87
|
-
- - ">="
|
88
|
-
- !ruby/object:Gem::Version
|
89
|
-
version: '0'
|
90
|
-
type: :development
|
91
|
-
prerelease: false
|
92
|
-
version_requirements: !ruby/object:Gem::Requirement
|
93
|
-
requirements:
|
94
|
-
- - ">="
|
95
|
-
- !ruby/object:Gem::Version
|
96
|
-
version: '0'
|
97
|
-
- !ruby/object:Gem::Dependency
|
98
|
-
name: webmock
|
99
|
-
requirement: !ruby/object:Gem::Requirement
|
100
|
-
requirements:
|
101
|
-
- - ">="
|
102
|
-
- !ruby/object:Gem::Version
|
103
|
-
version: '0'
|
104
|
-
type: :development
|
105
|
-
prerelease: false
|
106
|
-
version_requirements: !ruby/object:Gem::Requirement
|
107
|
-
requirements:
|
108
|
-
- - ">="
|
109
|
-
- !ruby/object:Gem::Version
|
110
|
-
version: '0'
|
111
41
|
description: This is the strategy for authenticating to your Tanmer service
|
112
42
|
email:
|
113
43
|
- xiaohui@tanmer.com
|