dalliance 0.7.0 → 0.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -197,7 +197,7 @@ module Dalliance
197
197
  def validate_dalliance_status
198
198
  unless error_or_completed?
199
199
  errors.add(:dalliance_status, :invalid)
200
- if defined?(Rails) && ::Rails::VERSION::MAJOR == 5 && ::Rails::VERSION::MINOR >= 0
200
+ if defined?(Rails)
201
201
  throw(:abort)
202
202
  else
203
203
  return false
@@ -1,7 +1,7 @@
1
1
  module Dalliance
2
2
  module VERSION
3
3
  MAJOR = 0
4
- MINOR = 7
4
+ MINOR = 8
5
5
  TINY = 0
6
6
  PRE = nil
7
7
 
@@ -1,6 +1,6 @@
1
1
  module Dalliance
2
2
  module Workers
3
- if defined?(Rails) && ((::Rails::VERSION::MAJOR == 4 && ::Rails::VERSION::MINOR >= 2) || ::Rails::VERSION::MAJOR >= 5)
3
+ if defined?(Rails)
4
4
  class DelayedJob < ::ActiveJob::Base
5
5
  queue_as :dalliance
6
6
 
@@ -1,6 +1,6 @@
1
1
  module Dalliance
2
2
  module Workers
3
- if defined?(Rails) && ((::Rails::VERSION::MAJOR == 4 && ::Rails::VERSION::MINOR >= 2) || ::Rails::VERSION::MAJOR >= 5)
3
+ if defined?(Rails)
4
4
  class Resque < ::ActiveJob::Base
5
5
  queue_as :dalliance
6
6
 
@@ -79,6 +79,7 @@ RSpec.describe DallianceModel do
79
79
 
80
80
  context 'reprocess' do
81
81
  before(:all) do
82
+ DallianceModel.dalliance_options[:dalliance_method] = :dalliance_success_method
82
83
  DallianceModel.dalliance_options[:worker_class] = Dalliance::Workers::DelayedJob
83
84
  DallianceModel.dalliance_options[:queue] = 'dalliance'
84
85
  end
@@ -116,6 +116,7 @@ RSpec.describe DallianceModel do
116
116
 
117
117
  context 'reprocess' do
118
118
  before :all do
119
+ DallianceModel.dalliance_options[:dalliance_method] = :dalliance_success_method
119
120
  DallianceModel.dalliance_options[:worker_class] = Dalliance::Workers::Resque
120
121
  DallianceModel.dalliance_options[:queue] = 'dalliance'
121
122
  end
@@ -48,6 +48,7 @@ RSpec.describe DallianceModel do
48
48
 
49
49
  context 'when the model has already processed' do
50
50
  before do
51
+ DallianceModel.dalliance_options[:dalliance_method] = :dalliance_success_method
51
52
  subject.dalliance_background_process
52
53
  subject.reload
53
54
  end
@@ -175,7 +176,7 @@ RSpec.describe DallianceModel do
175
176
  end
176
177
  end
177
178
 
178
- context "destroy" do
179
+ context "destroy" do
179
180
  it "should return false when pending?" do
180
181
  subject.update_column(:dalliance_status, 'pending')
181
182
  expect(subject.destroy).to be_falsey
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dalliance
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.7.0
4
+ version: 0.8.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Eric Sullivan
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-02-12 00:00:00.000000000 Z
11
+ date: 2020-02-28 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -16,20 +16,20 @@ dependencies:
16
16
  requirements:
17
17
  - - ">="
18
18
  - !ruby/object:Gem::Version
19
- version: '4.2'
19
+ version: '5.0'
20
20
  - - "<"
21
21
  - !ruby/object:Gem::Version
22
- version: '5.3'
22
+ version: '6.1'
23
23
  type: :runtime
24
24
  prerelease: false
25
25
  version_requirements: !ruby/object:Gem::Requirement
26
26
  requirements:
27
27
  - - ">="
28
28
  - !ruby/object:Gem::Version
29
- version: '4.2'
29
+ version: '5.0'
30
30
  - - "<"
31
31
  - !ruby/object:Gem::Version
32
- version: '5.3'
32
+ version: '6.1'
33
33
  - !ruby/object:Gem::Dependency
34
34
  name: state_machine
35
35
  requirement: !ruby/object:Gem::Requirement
@@ -174,14 +174,14 @@ files:
174
174
  - Rakefile
175
175
  - config/locales/en.yml
176
176
  - dalliance.gemspec
177
- - gemfiles/rails_4.2.gemfile
178
- - gemfiles/rails_4.2.gemfile.lock
179
177
  - gemfiles/rails_5.0.gemfile
180
178
  - gemfiles/rails_5.0.gemfile.lock
181
179
  - gemfiles/rails_5.1.gemfile
182
180
  - gemfiles/rails_5.1.gemfile.lock
183
181
  - gemfiles/rails_5.2.gemfile
184
182
  - gemfiles/rails_5.2.gemfile.lock
183
+ - gemfiles/rails_6.0.gemfile
184
+ - gemfiles/rails_6.0.gemfile.lock
185
185
  - lib/dalliance.rb
186
186
  - lib/dalliance/engine.rb
187
187
  - lib/dalliance/progress_meter.rb
@@ -1,165 +0,0 @@
1
- PATH
2
- remote: ..
3
- specs:
4
- dalliance (0.5.1)
5
- rails (>= 3.2, < 5.3)
6
- state_machine
7
-
8
- GEM
9
- remote: https://rubygems.org/
10
- specs:
11
- actionmailer (4.2.9)
12
- actionpack (= 4.2.9)
13
- actionview (= 4.2.9)
14
- activejob (= 4.2.9)
15
- mail (~> 2.5, >= 2.5.4)
16
- rails-dom-testing (~> 1.0, >= 1.0.5)
17
- actionpack (4.2.9)
18
- actionview (= 4.2.9)
19
- activesupport (= 4.2.9)
20
- rack (~> 1.6)
21
- rack-test (~> 0.6.2)
22
- rails-dom-testing (~> 1.0, >= 1.0.5)
23
- rails-html-sanitizer (~> 1.0, >= 1.0.2)
24
- actionview (4.2.9)
25
- activesupport (= 4.2.9)
26
- builder (~> 3.1)
27
- erubis (~> 2.7.0)
28
- rails-dom-testing (~> 1.0, >= 1.0.5)
29
- rails-html-sanitizer (~> 1.0, >= 1.0.3)
30
- activejob (4.2.9)
31
- activesupport (= 4.2.9)
32
- globalid (>= 0.3.0)
33
- activemodel (4.2.9)
34
- activesupport (= 4.2.9)
35
- builder (~> 3.1)
36
- activerecord (4.2.9)
37
- activemodel (= 4.2.9)
38
- activesupport (= 4.2.9)
39
- arel (~> 6.0)
40
- activesupport (4.2.9)
41
- i18n (~> 0.7)
42
- minitest (~> 5.1)
43
- thread_safe (~> 0.3, >= 0.3.4)
44
- tzinfo (~> 1.1)
45
- appraisal (2.2.0)
46
- bundler
47
- rake
48
- thor (>= 0.14.0)
49
- arel (6.0.4)
50
- builder (3.2.3)
51
- byebug (10.0.2)
52
- concurrent-ruby (1.1.5)
53
- crass (1.0.4)
54
- delayed_job (4.1.5)
55
- activesupport (>= 3.0, < 5.3)
56
- delayed_job_active_record (4.1.3)
57
- activerecord (>= 3.0, < 5.3)
58
- delayed_job (>= 3.0, < 5)
59
- diff-lcs (1.3)
60
- erubis (2.7.0)
61
- globalid (0.4.2)
62
- activesupport (>= 4.2.0)
63
- i18n (0.9.5)
64
- concurrent-ruby (~> 1.0)
65
- loofah (2.2.3)
66
- crass (~> 1.0.2)
67
- nokogiri (>= 1.5.9)
68
- mail (2.7.1)
69
- mini_mime (>= 0.1.1)
70
- mini_mime (1.0.1)
71
- mini_portile2 (2.4.0)
72
- minitest (5.11.3)
73
- mono_logger (1.1.0)
74
- multi_json (1.13.1)
75
- nokogiri (1.10.3)
76
- mini_portile2 (~> 2.4.0)
77
- rack (1.6.8)
78
- rack-protection (1.5.3)
79
- rack
80
- rack-test (0.6.3)
81
- rack (>= 1.0)
82
- rails (4.2.9)
83
- actionmailer (= 4.2.9)
84
- actionpack (= 4.2.9)
85
- actionview (= 4.2.9)
86
- activejob (= 4.2.9)
87
- activemodel (= 4.2.9)
88
- activerecord (= 4.2.9)
89
- activesupport (= 4.2.9)
90
- bundler (>= 1.3.0, < 2.0)
91
- railties (= 4.2.9)
92
- sprockets-rails
93
- rails-deprecated_sanitizer (1.0.3)
94
- activesupport (>= 4.2.0.alpha)
95
- rails-dom-testing (1.0.9)
96
- activesupport (>= 4.2.0, < 5.0)
97
- nokogiri (~> 1.6)
98
- rails-deprecated_sanitizer (>= 1.0.1)
99
- rails-html-sanitizer (1.0.4)
100
- loofah (~> 2.2, >= 2.2.2)
101
- railties (4.2.9)
102
- actionpack (= 4.2.9)
103
- activesupport (= 4.2.9)
104
- rake (>= 0.8.7)
105
- thor (>= 0.18.1, < 2.0)
106
- rake (12.3.2)
107
- redis (4.1.0)
108
- redis-namespace (1.6.0)
109
- redis (>= 3.0.4)
110
- resque (2.0.0)
111
- mono_logger (~> 1.0)
112
- multi_json (~> 1.0)
113
- redis-namespace (~> 1.6)
114
- sinatra (>= 0.9.2)
115
- vegas (~> 0.1.2)
116
- rspec (3.8.0)
117
- rspec-core (~> 3.8.0)
118
- rspec-expectations (~> 3.8.0)
119
- rspec-mocks (~> 3.8.0)
120
- rspec-core (3.8.0)
121
- rspec-support (~> 3.8.0)
122
- rspec-expectations (3.8.2)
123
- diff-lcs (>= 1.2.0, < 2.0)
124
- rspec-support (~> 3.8.0)
125
- rspec-mocks (3.8.0)
126
- diff-lcs (>= 1.2.0, < 2.0)
127
- rspec-support (~> 3.8.0)
128
- rspec-support (3.8.0)
129
- sinatra (1.4.8)
130
- rack (~> 1.5)
131
- rack-protection (~> 1.4)
132
- tilt (>= 1.3, < 3)
133
- sprockets (3.7.2)
134
- concurrent-ruby (~> 1.0)
135
- rack (> 1, < 3)
136
- sprockets-rails (3.2.1)
137
- actionpack (>= 4.0)
138
- activesupport (>= 4.0)
139
- sprockets (>= 3.0.0)
140
- sqlite3 (1.3.13)
141
- state_machine (1.2.0)
142
- thor (0.20.3)
143
- thread_safe (0.3.6)
144
- tilt (2.0.9)
145
- tzinfo (1.2.5)
146
- thread_safe (~> 0.1)
147
- vegas (0.1.11)
148
- rack (>= 1.0.0)
149
-
150
- PLATFORMS
151
- ruby
152
-
153
- DEPENDENCIES
154
- appraisal
155
- byebug
156
- dalliance!
157
- delayed_job (>= 3.0.0)
158
- delayed_job_active_record
159
- rails (~> 4.2.0)
160
- resque
161
- rspec (>= 3.0.0)
162
- sqlite3
163
-
164
- BUNDLED WITH
165
- 1.17.3