services 5.1.1 → 5.1.2

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: 198aaab5dbd57283d7ceda11637e42851b9b2d4a
4
- data.tar.gz: 2041ea64c62716706eb62e61e331fa4db9afda41
3
+ metadata.gz: 33dadcc06c08949fdc4e4e93559ff64582eb87a4
4
+ data.tar.gz: 3e0c26700eb5ca56247d1c3af47d763b5f5eb69b
5
5
  SHA512:
6
- metadata.gz: 38dd5e81a6465ccb59b7344fa856e97b589ffab67d2a5ad528835968af73e96b5f07712d4737580075e88b63f58d650193644d1acc160fb35ee4344f31e79d07
7
- data.tar.gz: 479ffc18a349655cb744eb2d3d6210399285fcb70f11dc8c5162011536b9f5df99c400ddd2a9594125097e790a301e9ad67fdda0d0303593b19fb36095447fd4
6
+ metadata.gz: a48465b9e64aab633b7a302474a7b89d9ab5b49ac328c63c7d63c6b84eae3ead24a4fb0e9b36ea75879641a31ccc8ba766bad15b1ea512673096c0a6df5dde2c
7
+ data.tar.gz: 20f7242e49ecee857233982f512f90ea1d39831c20d29128cf42c726ec6d15287a0adc1de8f65901aa1dfb5d17a275e5e88bc53a47cad6b88022c5bc09757d53
@@ -10,13 +10,6 @@ before_install:
10
10
  - gem update --system
11
11
  - gem update bundler
12
12
  gemfile:
13
- - gemfiles/rails_4.0.gemfile
14
- - gemfiles/rails_4.1.gemfile
15
13
  - gemfiles/rails_4.2.gemfile
16
14
  - gemfiles/rails_5.0.gemfile
17
- matrix:
18
- exclude:
19
- - rvm: 2.4.0
20
- gemfile: gemfiles/rails_4.0.gemfile
21
- - rvm: 2.4.0
22
- gemfile: gemfiles/rails_4.1.gemfile
15
+ - gemfiles/rails_5.1.gemfile
data/Appraisals CHANGED
@@ -1,11 +1,3 @@
1
- appraise 'rails_4.0' do
2
- gem 'rails', '~> 4.0.0'
3
- end
4
-
5
- appraise 'rails_4.1' do
6
- gem 'rails', '~> 4.1.0'
7
- end
8
-
9
1
  appraise 'rails_4.2' do
10
2
  gem 'rails', '~> 4.2.0'
11
3
  end
@@ -13,3 +5,7 @@ end
13
5
  appraise 'rails_5.0' do
14
6
  gem 'rails', '~> 5.0.0'
15
7
  end
8
+
9
+ appraise 'rails_5.1' do
10
+ gem 'rails', '~> 5.1.0'
11
+ end
data/README.md CHANGED
@@ -21,7 +21,7 @@ For disambiguation: in this README, when you read "Services" with a uppercase "S
21
21
 
22
22
  #### Ruby >= 2.2.5
23
23
 
24
- #### Rails >= 4.0
24
+ #### Rails >= 4.2
25
25
 
26
26
  #### Redis >= 3.0
27
27
 
@@ -2,6 +2,6 @@
2
2
 
3
3
  source "https://rubygems.org"
4
4
 
5
- gem "rails", "~> 4.0.0"
5
+ gem "rails", "~> 5.1.0"
6
6
 
7
7
  gemspec :path => "../"
@@ -23,7 +23,7 @@ module Services
23
23
  special_conditions = conditions.extract!(:order, :limit, :page, :per_page)
24
24
  special_conditions[:order] = object_table_id unless special_conditions.has_key?(:order)
25
25
 
26
- scope = conditions.delete(:scope) || object_class.public_send(ActiveRecord::VERSION::MAJOR == 3 ? :scoped : :all)
26
+ scope = conditions.delete(:scope).try(:dup) || object_class.public_send(ActiveRecord::VERSION::MAJOR == 3 ? :scoped : :all)
27
27
  scope = scope.where(object_table_id => ids) unless ids.empty?
28
28
 
29
29
  unless conditions.empty?
@@ -1,3 +1,3 @@
1
1
  module Services
2
- VERSION = '5.1.1'.freeze
2
+ VERSION = '5.1.2'.freeze
3
3
  end
@@ -31,6 +31,6 @@ Gem::Specification.new do |gem|
31
31
  gem.add_development_dependency 'timecop', '~> 0.7'
32
32
  gem.add_development_dependency 'sqlite3', '~> 1.3'
33
33
  gem.add_development_dependency 'appraisal', '~> 2.1'
34
- gem.add_runtime_dependency 'rails', '>= 4.0.0'
34
+ gem.add_runtime_dependency 'rails', '>= 4.2'
35
35
  gem.add_runtime_dependency 'gem_config', '~> 0.3'
36
36
  end
@@ -13,7 +13,7 @@ describe Services::Base::CallLogger do
13
13
  meta: {
14
14
  caller: a_string_matching(caller_regex),
15
15
  service: service.class.to_s,
16
- id: an_instance_of(String)
16
+ id: a_kind_of(String)
17
17
  },
18
18
  severity: 'info'
19
19
  )
@@ -22,7 +22,7 @@ describe Services::Base::CallLogger do
22
22
  meta: {
23
23
  duration: a_value_within(0.1).of(0.0),
24
24
  service: service.class.to_s,
25
- id: an_instance_of(String)
25
+ id: a_kind_of(String)
26
26
  },
27
27
  severity: 'info'
28
28
  )
@@ -57,7 +57,7 @@ shared_examples 'checking the uniqueness properly' do
57
57
  fail_args.each do |fail_arg_group|
58
58
  service = service_class.new
59
59
  expect(service).to_not receive(:do_work)
60
- expect(service_class).to receive(:call_in).with(an_instance_of(Integer), *fail_arg_group, 'reschedule', false)
60
+ expect(service_class).to receive(:call_in).with(a_kind_of(Integer), *fail_arg_group, 'reschedule', false)
61
61
  expect { service.call(*fail_arg_group, 'reschedule', false) }.to_not raise_error
62
62
  end
63
63
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: services
3
3
  version: !ruby/object:Gem::Version
4
- version: 5.1.1
4
+ version: 5.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Manuel Meurer
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-03-31 00:00:00.000000000 Z
11
+ date: 2017-11-01 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake
@@ -156,14 +156,14 @@ dependencies:
156
156
  requirements:
157
157
  - - ">="
158
158
  - !ruby/object:Gem::Version
159
- version: 4.0.0
159
+ version: '4.2'
160
160
  type: :runtime
161
161
  prerelease: false
162
162
  version_requirements: !ruby/object:Gem::Requirement
163
163
  requirements:
164
164
  - - ">="
165
165
  - !ruby/object:Gem::Version
166
- version: 4.0.0
166
+ version: '4.2'
167
167
  - !ruby/object:Gem::Dependency
168
168
  name: gem_config
169
169
  requirement: !ruby/object:Gem::Requirement
@@ -193,10 +193,9 @@ files:
193
193
  - LICENSE.txt
194
194
  - README.md
195
195
  - Rakefile
196
- - gemfiles/rails_4.0.gemfile
197
- - gemfiles/rails_4.1.gemfile
198
196
  - gemfiles/rails_4.2.gemfile
199
197
  - gemfiles/rails_5.0.gemfile
198
+ - gemfiles/rails_5.1.gemfile
200
199
  - lib/services.rb
201
200
  - lib/services/asyncable.rb
202
201
  - lib/services/base.rb
@@ -247,7 +246,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
247
246
  version: '0'
248
247
  requirements: []
249
248
  rubyforge_project:
250
- rubygems_version: 2.6.11
249
+ rubygems_version: 2.6.13
251
250
  signing_key:
252
251
  specification_version: 4
253
252
  summary: A nifty service layer for your Rails app
@@ -1,7 +0,0 @@
1
- # This file was generated by Appraisal
2
-
3
- source "https://rubygems.org"
4
-
5
- gem "rails", "~> 4.1.0"
6
-
7
- gemspec :path => "../"