omniauth-gitlab 2.0.0 → 4.0.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
- SHA1:
3
- metadata.gz: dde62b5d8d0b62f40619ade7d5a970f00f386c43
4
- data.tar.gz: abd7240506cd709572a516349b5e9f415c659450
2
+ SHA256:
3
+ metadata.gz: 136ee3cebba142f927c036e6be577c54f914a58df37a4ee5576b49c115a32be3
4
+ data.tar.gz: 21ff902a4cd932a94b73e26deba00a79bb74f26d34b0de14b64192b981b72b29
5
5
  SHA512:
6
- metadata.gz: e676d1f63ebefd66f99250304ebee6881378c1300aa6e9bd022101bf80585c1f797c2109a09d2e1538f5eb3ebf68c4e3bb2ac4a8848f0d63198c580fc3745d0c
7
- data.tar.gz: cefc322b57b91b07618c1265d356868298a3fe11c11480b131c5b55479aaacf3c706460965852fa0325bd046de1ecf5191171daec67747d6e731aba9c17cce4d
6
+ metadata.gz: b80fc28abd0072f3647df64a8a217320247cdeee58aeed0f199ad202d140ed41c8fb10468ac8c30ccddd7f669b17c33af5e6c2f0d3021c6afaaf5bc927c523a5
7
+ data.tar.gz: 1360523616245319d90efcf1ed01c4430b3dadcf0505566f2dd284d8904b75ad538cb28031fdd0b90729a8e395f2da95a1b18df9974298b2b5e18d4abaad964b
@@ -0,0 +1,21 @@
1
+ name: CI
2
+
3
+ on: [push, pull_request]
4
+
5
+ jobs:
6
+ test:
7
+ runs-on: ubuntu-latest
8
+ strategy:
9
+ matrix:
10
+ ruby-version: ['2.6', '2.7', '3.0', '3.1']
11
+
12
+ steps:
13
+ - uses: actions/checkout@v2
14
+ - name: Set up Ruby ${{ matrix.ruby-version }}
15
+ uses: ruby/setup-ruby@v1
16
+ with:
17
+ ruby-version: ${{ matrix.ruby-version }}
18
+ bundler-cache: true # 'bundle install' and cache
19
+ - name: Run specs
20
+ run: |
21
+ bundle exec rspec
@@ -4,7 +4,7 @@ require 'omniauth-oauth2'
4
4
  module OmniAuth
5
5
  module Strategies
6
6
  class GitLab < OmniAuth::Strategies::OAuth2
7
- option :client_options, site: 'https://gitlab.com/api/v4'
7
+ option :client_options, site: 'https://gitlab.com'
8
8
 
9
9
  option :redirect_url
10
10
 
@@ -24,7 +24,7 @@ module OmniAuth
24
24
  end
25
25
 
26
26
  def raw_info
27
- @raw_info ||= access_token.get('user').parsed
27
+ @raw_info ||= access_token.get('api/v4/user').parsed
28
28
  end
29
29
 
30
30
  private
@@ -1,5 +1,5 @@
1
1
  module Omniauth
2
2
  module Gitlab
3
- VERSION = '2.0.0'
3
+ VERSION = '4.0.0'
4
4
  end
5
5
  end
@@ -17,8 +17,8 @@ Gem::Specification.new do |gem|
17
17
  gem.test_files = gem.files.grep(%r{^(test|spec|features)/})
18
18
  gem.require_paths = ['lib']
19
19
 
20
- gem.add_dependency 'omniauth', '~> 1.0'
21
- gem.add_dependency 'omniauth-oauth2', '~> 1.0'
20
+ gem.add_dependency 'omniauth', '~> 2.0'
21
+ gem.add_dependency 'omniauth-oauth2', '~> 1.7.1'
22
22
  gem.add_development_dependency 'rspec', '~> 3.1'
23
23
  gem.add_development_dependency 'rspec-its', '~> 1.0'
24
24
  gem.add_development_dependency 'simplecov'
@@ -27,7 +27,7 @@ describe OmniAuth::Strategies::GitLab do
27
27
  context 'with defaults' do
28
28
  subject { gitlab_service.options.client_options }
29
29
 
30
- its(:site) { is_expected.to eq 'https://gitlab.com/api/v4' }
30
+ its(:site) { is_expected.to eq 'https://gitlab.com' }
31
31
  end
32
32
 
33
33
  context 'with override' do
@@ -51,7 +51,7 @@ describe OmniAuth::Strategies::GitLab do
51
51
 
52
52
  describe '#raw_info' do
53
53
  it 'sent request to current user endpoint' do
54
- expect(access_token).to receive(:get).with('user').and_return(response)
54
+ expect(access_token).to receive(:get).with('api/v4/user').and_return(response)
55
55
  expect(subject.raw_info).to eq(parsed_response)
56
56
  end
57
57
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: omniauth-gitlab
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.0
4
+ version: 4.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sergey Sein
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-08-24 00:00:00.000000000 Z
11
+ date: 2022-04-19 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: omniauth
@@ -16,28 +16,28 @@ dependencies:
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: '1.0'
19
+ version: '2.0'
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: '1.0'
26
+ version: '2.0'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: omniauth-oauth2
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
31
  - - "~>"
32
32
  - !ruby/object:Gem::Version
33
- version: '1.0'
33
+ version: 1.7.1
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - "~>"
39
39
  - !ruby/object:Gem::Version
40
- version: '1.0'
40
+ version: 1.7.1
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: rspec
43
43
  requirement: !ruby/object:Gem::Requirement
@@ -101,6 +101,7 @@ executables: []
101
101
  extensions: []
102
102
  extra_rdoc_files: []
103
103
  files:
104
+ - ".github/workflows/ruby.yml"
104
105
  - ".gitignore"
105
106
  - ".project"
106
107
  - ".rspec"
@@ -132,8 +133,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
132
133
  - !ruby/object:Gem::Version
133
134
  version: '0'
134
135
  requirements: []
135
- rubyforge_project:
136
- rubygems_version: 2.5.2
136
+ rubygems_version: 3.1.4
137
137
  signing_key:
138
138
  specification_version: 4
139
139
  summary: This is the strategy for authenticating to your GitLab service