run_after_commit 0.0.1
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.
- data/.gitignore +15 -0
- data/.travis.yml +29 -0
- data/Appraisals +21 -0
- data/Gemfile +11 -0
- data/LICENSE.txt +22 -0
- data/README.md +50 -0
- data/Rakefile +9 -0
- data/gemfiles/3.2.gemfile +14 -0
- data/gemfiles/4.0.gemfile +14 -0
- data/gemfiles/4.1.gemfile +14 -0
- data/gemfiles/4.2.gemfile +14 -0
- data/lib/run_after_commit.rb +39 -0
- data/lib/run_after_commit/version.rb +3 -0
- data/run_after_commit.gemspec +27 -0
- data/test/database.yml +17 -0
- data/test/run_after_commit_test.rb +148 -0
- data/test/test_helper.rb +53 -0
- metadata +162 -0
data/.gitignore
ADDED
data/.travis.yml
ADDED
@@ -0,0 +1,29 @@
|
|
1
|
+
|
2
|
+
addons:
|
3
|
+
postgresql: "9.3"
|
4
|
+
|
5
|
+
before_script:
|
6
|
+
- mysql -e 'create database run_after_commit;'
|
7
|
+
- psql -c 'create database run_after_commit;' -U postgres
|
8
|
+
|
9
|
+
rvm:
|
10
|
+
- 1.9.3
|
11
|
+
- 2.0.0
|
12
|
+
- 2.1.1
|
13
|
+
env:
|
14
|
+
- DATABASE=sqlite
|
15
|
+
- DATABASE=mysql
|
16
|
+
- DATABASE=postgres
|
17
|
+
|
18
|
+
gemfile:
|
19
|
+
- gemfiles/3.2.gemfile
|
20
|
+
- gemfiles/4.0.gemfile
|
21
|
+
- gemfiles/4.1.gemfile
|
22
|
+
- gemfiles/4.2.gemfile
|
23
|
+
|
24
|
+
install:
|
25
|
+
- "travis_retry bundle install"
|
26
|
+
|
27
|
+
script: "bundle exec rake test"
|
28
|
+
sudo: false
|
29
|
+
|
data/Appraisals
ADDED
@@ -0,0 +1,21 @@
|
|
1
|
+
|
2
|
+
appraise "3.2" do
|
3
|
+
gem "activerecord", "~> 3.2.18"
|
4
|
+
gem "run_after_commit", :path => "../"
|
5
|
+
end
|
6
|
+
|
7
|
+
appraise "4.0" do
|
8
|
+
gem "activerecord", "~> 4.0.0"
|
9
|
+
gem "run_after_commit", :path => "../"
|
10
|
+
end
|
11
|
+
|
12
|
+
appraise "4.1" do
|
13
|
+
gem "activerecord", "~> 4.1.0.beta"
|
14
|
+
gem "run_after_commit", :path => "../"
|
15
|
+
end
|
16
|
+
|
17
|
+
appraise "4.2" do
|
18
|
+
gem "activerecord", "~> 4.2.0.beta"
|
19
|
+
gem "run_after_commit", :path => "../"
|
20
|
+
end
|
21
|
+
|
data/Gemfile
ADDED
data/LICENSE.txt
ADDED
@@ -0,0 +1,22 @@
|
|
1
|
+
Copyright (c) 2015 Benjamin Vetter
|
2
|
+
|
3
|
+
MIT License
|
4
|
+
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
6
|
+
a copy of this software and associated documentation files (the
|
7
|
+
"Software"), to deal in the Software without restriction, including
|
8
|
+
without limitation the rights to use, copy, modify, merge, publish,
|
9
|
+
distribute, sublicense, and/or sell copies of the Software, and to
|
10
|
+
permit persons to whom the Software is furnished to do so, subject to
|
11
|
+
the following conditions:
|
12
|
+
|
13
|
+
The above copyright notice and this permission notice shall be
|
14
|
+
included in all copies or substantial portions of the Software.
|
15
|
+
|
16
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
17
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
18
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
19
|
+
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
20
|
+
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
21
|
+
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
22
|
+
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
data/README.md
ADDED
@@ -0,0 +1,50 @@
|
|
1
|
+
# RunAfterCommit
|
2
|
+
|
3
|
+
[](http://travis-ci.org/mrkamel/run_after_commit)
|
4
|
+
|
5
|
+
Run code in an ActiveRecord model after it is committed
|
6
|
+
or immediately if you're outside of a transaction.
|
7
|
+
|
8
|
+
Requires ActiveRecord 3.2+ (Check travis)
|
9
|
+
|
10
|
+
## Installation
|
11
|
+
|
12
|
+
Add this line to your application's Gemfile:
|
13
|
+
|
14
|
+
```ruby
|
15
|
+
gem 'run_after_commit'
|
16
|
+
```
|
17
|
+
|
18
|
+
And then execute:
|
19
|
+
|
20
|
+
$ bundle
|
21
|
+
|
22
|
+
Or install it yourself as:
|
23
|
+
|
24
|
+
$ gem install run_after_commit
|
25
|
+
|
26
|
+
## Usage
|
27
|
+
|
28
|
+
Include `RunAfterCommit` in your model and queue some code:
|
29
|
+
|
30
|
+
```ruby
|
31
|
+
class SomeModel < ActiveRecord::Base
|
32
|
+
include RunAfterCommit
|
33
|
+
|
34
|
+
after_save :some_method
|
35
|
+
|
36
|
+
def some_method
|
37
|
+
run_after_commit do
|
38
|
+
# Runs when the model is committed
|
39
|
+
end
|
40
|
+
end
|
41
|
+
end
|
42
|
+
```
|
43
|
+
|
44
|
+
## Contributing
|
45
|
+
|
46
|
+
1. Fork it ( https://github.com/mrkamel/run_after_commit/fork )
|
47
|
+
2. Create your feature branch (`git checkout -b my-new-feature`)
|
48
|
+
3. Commit your changes (`git commit -am 'Add some feature'`)
|
49
|
+
4. Push to the branch (`git push origin my-new-feature`)
|
50
|
+
5. Create a new Pull Request
|
data/Rakefile
ADDED
@@ -0,0 +1,39 @@
|
|
1
|
+
|
2
|
+
require "run_after_commit/version"
|
3
|
+
|
4
|
+
module RunAfterCommit
|
5
|
+
def self.included(base)
|
6
|
+
base.after_commit :run_after_commit_queue
|
7
|
+
base.after_rollback :clear_after_commit_queue
|
8
|
+
end
|
9
|
+
|
10
|
+
def run_after_commit(method = nil, &block)
|
11
|
+
after_commit_queue << Proc.new { send method } if method
|
12
|
+
after_commit_queue << block if block
|
13
|
+
|
14
|
+
run_after_commit_queue if self.class.connection.open_transactions.zero?
|
15
|
+
|
16
|
+
true
|
17
|
+
end
|
18
|
+
|
19
|
+
protected
|
20
|
+
|
21
|
+
def run_after_commit_queue
|
22
|
+
after_commit_queue.each do |action|
|
23
|
+
self.instance_eval(&action)
|
24
|
+
end
|
25
|
+
ensure
|
26
|
+
clear_after_commit_queue
|
27
|
+
end
|
28
|
+
|
29
|
+
def after_commit_queue
|
30
|
+
self.class.connection.instance_variable_get("@run_after_commit_queue") || self.class.connection.instance_variable_set("@run_after_commit_queue", [])
|
31
|
+
end
|
32
|
+
|
33
|
+
def clear_after_commit_queue
|
34
|
+
self.class.connection.instance_variable_set "@run_after_commit_queue", []
|
35
|
+
|
36
|
+
true
|
37
|
+
end
|
38
|
+
end
|
39
|
+
|
@@ -0,0 +1,27 @@
|
|
1
|
+
# coding: utf-8
|
2
|
+
lib = File.expand_path('../lib', __FILE__)
|
3
|
+
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
4
|
+
require 'run_after_commit/version'
|
5
|
+
|
6
|
+
Gem::Specification.new do |spec|
|
7
|
+
spec.name = "run_after_commit"
|
8
|
+
spec.version = RunAfterCommit::VERSION
|
9
|
+
spec.authors = ["Benjamin Vetter"]
|
10
|
+
spec.email = ["vetter@plainpicture.de"]
|
11
|
+
spec.summary = %q{Run code in an ActiveRecord model after it is committed}
|
12
|
+
spec.description = %q{Run code in an ActiveRecord model after it is committed}
|
13
|
+
spec.homepage = ""
|
14
|
+
spec.license = "MIT"
|
15
|
+
|
16
|
+
spec.files = `git ls-files -z`.split("\x0")
|
17
|
+
spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
|
18
|
+
spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
|
19
|
+
spec.require_paths = ["lib"]
|
20
|
+
|
21
|
+
spec.add_development_dependency "bundler", "~> 1.7"
|
22
|
+
spec.add_development_dependency "rake", "~> 10.0"
|
23
|
+
spec.add_development_dependency "activerecord", ">= 3.0.0"
|
24
|
+
spec.add_development_dependency "appraisal"
|
25
|
+
spec.add_development_dependency "minitest"
|
26
|
+
spec.add_development_dependency "hooks"
|
27
|
+
end
|
data/test/database.yml
ADDED
@@ -0,0 +1,17 @@
|
|
1
|
+
|
2
|
+
sqlite:
|
3
|
+
adapter: sqlite3
|
4
|
+
database: ":memory:"
|
5
|
+
|
6
|
+
mysql:
|
7
|
+
adapter: mysql2
|
8
|
+
database: run_after_commit
|
9
|
+
username: root
|
10
|
+
encoding: utf8
|
11
|
+
|
12
|
+
postgres:
|
13
|
+
adapter: postgresql
|
14
|
+
database: run_after_commit
|
15
|
+
username: postgres
|
16
|
+
encoding: utf8
|
17
|
+
|
@@ -0,0 +1,148 @@
|
|
1
|
+
|
2
|
+
require File.expand_path("../test_helper", __FILE__)
|
3
|
+
|
4
|
+
class RunAfterCommitTest < RunAfterCommit::TestCase
|
5
|
+
def test_default
|
6
|
+
test_model = TestModel.create!
|
7
|
+
|
8
|
+
res = []
|
9
|
+
|
10
|
+
test_model.after_save do
|
11
|
+
run_after_commit { res << "Block 1" }
|
12
|
+
run_after_commit { res << "Block 2" }
|
13
|
+
end
|
14
|
+
|
15
|
+
test_model.update_attributes! :title => "Title"
|
16
|
+
|
17
|
+
assert_equal ["Block 1", "Block 2"], res
|
18
|
+
|
19
|
+
res.clear
|
20
|
+
|
21
|
+
test_model.after_save do
|
22
|
+
run_after_commit { res << "Block 3" }
|
23
|
+
run_after_commit { res << "Block 4" }
|
24
|
+
end
|
25
|
+
|
26
|
+
test_model.update_attributes! :title => "Another title"
|
27
|
+
|
28
|
+
assert_equal ["Block 3", "Block 4"], res
|
29
|
+
end
|
30
|
+
|
31
|
+
def test_without_transaction
|
32
|
+
test_model = TestModel.create!
|
33
|
+
|
34
|
+
res = []
|
35
|
+
|
36
|
+
test_model.run_after_commit { res << "Block 1" }
|
37
|
+
|
38
|
+
assert_equal ["Block 1"], res
|
39
|
+
|
40
|
+
test_model.run_after_commit { res << "Block 2" }
|
41
|
+
|
42
|
+
assert_equal ["Block 1", "Block 2"], res
|
43
|
+
end
|
44
|
+
|
45
|
+
def test_empty
|
46
|
+
test_model = TestModel.create!
|
47
|
+
|
48
|
+
res = []
|
49
|
+
|
50
|
+
test_model.after_save do
|
51
|
+
test_model.run_after_commit { res << "Block" }
|
52
|
+
end
|
53
|
+
|
54
|
+
test_model.update_attributes! :title => "Title"
|
55
|
+
|
56
|
+
assert_equal ["Block"], res
|
57
|
+
|
58
|
+
res.clear
|
59
|
+
|
60
|
+
test_model.update_attributes! :title => "Another title"
|
61
|
+
|
62
|
+
assert_equal [], res
|
63
|
+
end
|
64
|
+
|
65
|
+
def test_rollback
|
66
|
+
test_model = TestModel.create!(:title => "Title")
|
67
|
+
|
68
|
+
res = []
|
69
|
+
|
70
|
+
ActiveRecord::Base.transaction do
|
71
|
+
test_model.run_after_commit { res << "Block" }
|
72
|
+
|
73
|
+
test_model.update_attributes! :title => "Another title"
|
74
|
+
|
75
|
+
raise ActiveRecord::Rollback
|
76
|
+
end
|
77
|
+
|
78
|
+
assert_equal "Title", test_model.reload.title
|
79
|
+
assert_equal [], res
|
80
|
+
|
81
|
+
test_model.update_attributes! :title => "Another title"
|
82
|
+
|
83
|
+
assert_equal [], res
|
84
|
+
end
|
85
|
+
|
86
|
+
def test_nested
|
87
|
+
test_model_1 = TestModel.create!
|
88
|
+
test_model_2 = TestModel.create!
|
89
|
+
|
90
|
+
res = []
|
91
|
+
|
92
|
+
ActiveRecord::Base.transaction do
|
93
|
+
test_model_1.run_after_commit { res << "Block 1" }
|
94
|
+
test_model_2.run_after_commit { res << "Block 2" }
|
95
|
+
|
96
|
+
test_model_1.update_attributes! :title => "Title 1"
|
97
|
+
test_model_2.update_attributes! :title => "Title 2"
|
98
|
+
|
99
|
+
assert_equal [], res
|
100
|
+
end
|
101
|
+
|
102
|
+
assert_equal ["Block 1", "Block 2"], res
|
103
|
+
|
104
|
+
res.clear
|
105
|
+
|
106
|
+
ActiveRecord::Base.transaction do
|
107
|
+
test_model_1.run_after_commit { res << "Block 3" }
|
108
|
+
test_model_2.run_after_commit { res << "Block 4" }
|
109
|
+
|
110
|
+
test_model_1.update_attributes! :title => "Another title 1"
|
111
|
+
test_model_2.update_attributes! :title => "Another title 2"
|
112
|
+
|
113
|
+
assert_equal [], res
|
114
|
+
end
|
115
|
+
|
116
|
+
assert_equal ["Block 3", "Block 4"], res
|
117
|
+
end
|
118
|
+
|
119
|
+
def test_instances
|
120
|
+
test_model = TestModel.create!
|
121
|
+
|
122
|
+
instance_1 = TestModel.find(test_model.id)
|
123
|
+
instance_2 = TestModel.find(test_model.id)
|
124
|
+
|
125
|
+
res = []
|
126
|
+
|
127
|
+
ActiveRecord::Base.transaction do
|
128
|
+
instance_1.run_after_commit { res << "Block 1" }
|
129
|
+
instance_2.run_after_commit { res << "Block 2" }
|
130
|
+
|
131
|
+
instance_1.update_attributes! :title => "Title 1"
|
132
|
+
instance_2.update_attributes! :title => "Title 2"
|
133
|
+
|
134
|
+
assert_equal [], res
|
135
|
+
end
|
136
|
+
|
137
|
+
assert_equal "Title 2", TestModel.find(test_model.id).title
|
138
|
+
assert_equal ["Block 1", "Block 2"], res
|
139
|
+
|
140
|
+
res.clear
|
141
|
+
|
142
|
+
instance_1.update_attributes! :title => "Title 1"
|
143
|
+
instance_2.update_attributes! :title => "Title 2"
|
144
|
+
|
145
|
+
assert_equal [], res
|
146
|
+
end
|
147
|
+
end
|
148
|
+
|
data/test/test_helper.rb
ADDED
@@ -0,0 +1,53 @@
|
|
1
|
+
|
2
|
+
require "run_after_commit"
|
3
|
+
|
4
|
+
begin
|
5
|
+
require "minitest"
|
6
|
+
|
7
|
+
class RunAfterCommit::TestCase < MiniTest::Test; end
|
8
|
+
rescue LoadError
|
9
|
+
require "minitest/unit"
|
10
|
+
|
11
|
+
class RunAfterCommit::TestCase < MiniTest::Unit::TestCase; end
|
12
|
+
end
|
13
|
+
|
14
|
+
require "minitest/autorun"
|
15
|
+
require "active_record"
|
16
|
+
require "yaml"
|
17
|
+
|
18
|
+
DATABASE = ENV["DATABASE"] || "sqlite"
|
19
|
+
|
20
|
+
ActiveRecord::Base.establish_connection YAML.load_file(File.expand_path("../database.yml", __FILE__))[DATABASE]
|
21
|
+
|
22
|
+
class TestModel < ActiveRecord::Base
|
23
|
+
include RunAfterCommit
|
24
|
+
|
25
|
+
def after_save(&block)
|
26
|
+
after_save_queue << block
|
27
|
+
end
|
28
|
+
|
29
|
+
after_save :run_after_save_queue
|
30
|
+
|
31
|
+
def run_after_save_queue
|
32
|
+
after_save_queue.each do |block|
|
33
|
+
instance_eval(&block)
|
34
|
+
end
|
35
|
+
ensure
|
36
|
+
clear_after_save_queue
|
37
|
+
end
|
38
|
+
|
39
|
+
def after_save_queue
|
40
|
+
@after_save_queue ||= []
|
41
|
+
end
|
42
|
+
|
43
|
+
def clear_after_save_queue
|
44
|
+
@after_save_queue = []
|
45
|
+
end
|
46
|
+
end
|
47
|
+
|
48
|
+
ActiveRecord::Base.connection.execute "DROP TABLE IF EXISTS test_models"
|
49
|
+
|
50
|
+
ActiveRecord::Base.connection.create_table :test_models do |t|
|
51
|
+
t.string :title
|
52
|
+
end
|
53
|
+
|
metadata
ADDED
@@ -0,0 +1,162 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: run_after_commit
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.0.1
|
5
|
+
prerelease:
|
6
|
+
platform: ruby
|
7
|
+
authors:
|
8
|
+
- Benjamin Vetter
|
9
|
+
autorequire:
|
10
|
+
bindir: bin
|
11
|
+
cert_chain: []
|
12
|
+
date: 2015-02-11 00:00:00.000000000 Z
|
13
|
+
dependencies:
|
14
|
+
- !ruby/object:Gem::Dependency
|
15
|
+
name: bundler
|
16
|
+
requirement: !ruby/object:Gem::Requirement
|
17
|
+
none: false
|
18
|
+
requirements:
|
19
|
+
- - ~>
|
20
|
+
- !ruby/object:Gem::Version
|
21
|
+
version: '1.7'
|
22
|
+
type: :development
|
23
|
+
prerelease: false
|
24
|
+
version_requirements: !ruby/object:Gem::Requirement
|
25
|
+
none: false
|
26
|
+
requirements:
|
27
|
+
- - ~>
|
28
|
+
- !ruby/object:Gem::Version
|
29
|
+
version: '1.7'
|
30
|
+
- !ruby/object:Gem::Dependency
|
31
|
+
name: rake
|
32
|
+
requirement: !ruby/object:Gem::Requirement
|
33
|
+
none: false
|
34
|
+
requirements:
|
35
|
+
- - ~>
|
36
|
+
- !ruby/object:Gem::Version
|
37
|
+
version: '10.0'
|
38
|
+
type: :development
|
39
|
+
prerelease: false
|
40
|
+
version_requirements: !ruby/object:Gem::Requirement
|
41
|
+
none: false
|
42
|
+
requirements:
|
43
|
+
- - ~>
|
44
|
+
- !ruby/object:Gem::Version
|
45
|
+
version: '10.0'
|
46
|
+
- !ruby/object:Gem::Dependency
|
47
|
+
name: activerecord
|
48
|
+
requirement: !ruby/object:Gem::Requirement
|
49
|
+
none: false
|
50
|
+
requirements:
|
51
|
+
- - ! '>='
|
52
|
+
- !ruby/object:Gem::Version
|
53
|
+
version: 3.0.0
|
54
|
+
type: :development
|
55
|
+
prerelease: false
|
56
|
+
version_requirements: !ruby/object:Gem::Requirement
|
57
|
+
none: false
|
58
|
+
requirements:
|
59
|
+
- - ! '>='
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: 3.0.0
|
62
|
+
- !ruby/object:Gem::Dependency
|
63
|
+
name: appraisal
|
64
|
+
requirement: !ruby/object:Gem::Requirement
|
65
|
+
none: false
|
66
|
+
requirements:
|
67
|
+
- - ! '>='
|
68
|
+
- !ruby/object:Gem::Version
|
69
|
+
version: '0'
|
70
|
+
type: :development
|
71
|
+
prerelease: false
|
72
|
+
version_requirements: !ruby/object:Gem::Requirement
|
73
|
+
none: false
|
74
|
+
requirements:
|
75
|
+
- - ! '>='
|
76
|
+
- !ruby/object:Gem::Version
|
77
|
+
version: '0'
|
78
|
+
- !ruby/object:Gem::Dependency
|
79
|
+
name: minitest
|
80
|
+
requirement: !ruby/object:Gem::Requirement
|
81
|
+
none: false
|
82
|
+
requirements:
|
83
|
+
- - ! '>='
|
84
|
+
- !ruby/object:Gem::Version
|
85
|
+
version: '0'
|
86
|
+
type: :development
|
87
|
+
prerelease: false
|
88
|
+
version_requirements: !ruby/object:Gem::Requirement
|
89
|
+
none: false
|
90
|
+
requirements:
|
91
|
+
- - ! '>='
|
92
|
+
- !ruby/object:Gem::Version
|
93
|
+
version: '0'
|
94
|
+
- !ruby/object:Gem::Dependency
|
95
|
+
name: hooks
|
96
|
+
requirement: !ruby/object:Gem::Requirement
|
97
|
+
none: false
|
98
|
+
requirements:
|
99
|
+
- - ! '>='
|
100
|
+
- !ruby/object:Gem::Version
|
101
|
+
version: '0'
|
102
|
+
type: :development
|
103
|
+
prerelease: false
|
104
|
+
version_requirements: !ruby/object:Gem::Requirement
|
105
|
+
none: false
|
106
|
+
requirements:
|
107
|
+
- - ! '>='
|
108
|
+
- !ruby/object:Gem::Version
|
109
|
+
version: '0'
|
110
|
+
description: Run code in an ActiveRecord model after it is committed
|
111
|
+
email:
|
112
|
+
- vetter@plainpicture.de
|
113
|
+
executables: []
|
114
|
+
extensions: []
|
115
|
+
extra_rdoc_files: []
|
116
|
+
files:
|
117
|
+
- .gitignore
|
118
|
+
- .travis.yml
|
119
|
+
- Appraisals
|
120
|
+
- Gemfile
|
121
|
+
- LICENSE.txt
|
122
|
+
- README.md
|
123
|
+
- Rakefile
|
124
|
+
- gemfiles/3.2.gemfile
|
125
|
+
- gemfiles/4.0.gemfile
|
126
|
+
- gemfiles/4.1.gemfile
|
127
|
+
- gemfiles/4.2.gemfile
|
128
|
+
- lib/run_after_commit.rb
|
129
|
+
- lib/run_after_commit/version.rb
|
130
|
+
- run_after_commit.gemspec
|
131
|
+
- test/database.yml
|
132
|
+
- test/run_after_commit_test.rb
|
133
|
+
- test/test_helper.rb
|
134
|
+
homepage: ''
|
135
|
+
licenses:
|
136
|
+
- MIT
|
137
|
+
post_install_message:
|
138
|
+
rdoc_options: []
|
139
|
+
require_paths:
|
140
|
+
- lib
|
141
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
142
|
+
none: false
|
143
|
+
requirements:
|
144
|
+
- - ! '>='
|
145
|
+
- !ruby/object:Gem::Version
|
146
|
+
version: '0'
|
147
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
148
|
+
none: false
|
149
|
+
requirements:
|
150
|
+
- - ! '>='
|
151
|
+
- !ruby/object:Gem::Version
|
152
|
+
version: '0'
|
153
|
+
requirements: []
|
154
|
+
rubyforge_project:
|
155
|
+
rubygems_version: 1.8.23
|
156
|
+
signing_key:
|
157
|
+
specification_version: 3
|
158
|
+
summary: Run code in an ActiveRecord model after it is committed
|
159
|
+
test_files:
|
160
|
+
- test/database.yml
|
161
|
+
- test/run_after_commit_test.rb
|
162
|
+
- test/test_helper.rb
|