bullet 4.6.0 → 4.7.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (69) hide show
  1. checksums.yaml +4 -4
  2. data/.gitignore +2 -1
  3. data/.ruby-gemset +1 -0
  4. data/.ruby-version +1 -0
  5. data/.travis.yml +10 -4
  6. data/Gemfile +4 -5
  7. data/Gemfile.lock +160 -0
  8. data/Gemfile.mongoid +15 -0
  9. data/Gemfile.mongoid-2.4.12 +15 -0
  10. data/Gemfile.mongoid-2.4.12.lock +163 -0
  11. data/Gemfile.mongoid-2.5.2 +15 -0
  12. data/Gemfile.mongoid-2.5.2.lock +163 -0
  13. data/Gemfile.mongoid-2.6.0 +15 -0
  14. data/Gemfile.mongoid-2.6.0.lock +163 -0
  15. data/Gemfile.mongoid-2.7.1 +15 -0
  16. data/Gemfile.mongoid-2.7.1.lock +163 -0
  17. data/Gemfile.mongoid-2.8.1 +15 -0
  18. data/Gemfile.mongoid-2.8.1.lock +166 -0
  19. data/Gemfile.mongoid-3.0.23 +15 -0
  20. data/Gemfile.mongoid-3.0.23.lock +163 -0
  21. data/Gemfile.mongoid-3.1.5 +15 -0
  22. data/Gemfile.mongoid-3.1.5.lock +163 -0
  23. data/Gemfile.mongoid.lock +167 -0
  24. data/Gemfile.rails-3.0.20 +3 -4
  25. data/Gemfile.rails-3.0.20.lock +147 -0
  26. data/Gemfile.rails-3.1.12 +14 -0
  27. data/Gemfile.rails-3.1.12.lock +157 -0
  28. data/Gemfile.rails-3.2.15 +14 -0
  29. data/Gemfile.rails-3.2.15.lock +155 -0
  30. data/Gemfile.rails-4.0.1 +14 -0
  31. data/Gemfile.rails-4.0.1.lock +150 -0
  32. data/README.md +16 -16
  33. data/bullet.gemspec +2 -1
  34. data/lib/bullet.rb +26 -2
  35. data/lib/bullet/dependency.rb +14 -23
  36. data/lib/bullet/mongoid4x.rb +55 -0
  37. data/lib/bullet/notification.rb +2 -0
  38. data/lib/bullet/notification/base.rb +4 -0
  39. data/lib/bullet/rack.rb +24 -3
  40. data/lib/bullet/version.rb +1 -1
  41. data/spec/bullet/detector/unused_eager_loading_spec.rb +1 -1
  42. data/spec/bullet/notification/base_spec.rb +2 -2
  43. data/spec/bullet/rack_spec.rb +9 -9
  44. data/spec/integration/{association_spec.rb → active_record3/association_spec.rb} +1 -1
  45. data/spec/integration/active_record4/association_spec.rb +698 -0
  46. data/spec/integration/mongoid/association_spec.rb +10 -7
  47. data/spec/models/client.rb +1 -1
  48. data/spec/models/comment.rb +2 -2
  49. data/spec/models/document.rb +2 -2
  50. data/spec/models/firm.rb +1 -1
  51. data/spec/models/mongoid/address.rb +2 -0
  52. data/spec/models/mongoid/category.rb +2 -0
  53. data/spec/models/mongoid/comment.rb +2 -0
  54. data/spec/models/mongoid/company.rb +2 -0
  55. data/spec/models/mongoid/entry.rb +2 -0
  56. data/spec/models/mongoid/post.rb +2 -0
  57. data/spec/models/mongoid/user.rb +2 -0
  58. data/spec/models/newspaper.rb +1 -1
  59. data/spec/models/pet.rb +1 -1
  60. data/spec/models/post.rb +3 -5
  61. data/spec/spec_helper.rb +21 -0
  62. data/spec/support/mongo_seed.rb +13 -1
  63. data/test.sh +12 -4
  64. metadata +49 -11
  65. data/.rvmrc +0 -2
  66. data/.rvmrc.example +0 -2
  67. data/Gemfile.rails-3.1.11 +0 -16
  68. data/Gemfile.rails-3.2.12 +0 -16
  69. data/Gemfile.rails-4-beta +0 -14
@@ -0,0 +1,15 @@
1
+ source "https://rubygems.org"
2
+
3
+ gemspec
4
+
5
+ gem 'rails'
6
+ gem 'sqlite3'
7
+ gem 'mysql2'
8
+ gem 'activerecord-import'
9
+ gem 'mongoid', '2.6.0'
10
+
11
+ gem "rspec"
12
+ gem "guard"
13
+ gem "guard-rspec"
14
+
15
+ gem 'coveralls', require: false
@@ -0,0 +1,163 @@
1
+ PATH
2
+ remote: .
3
+ specs:
4
+ bullet (4.7.0)
5
+ activesupport
6
+ uniform_notifier (>= 1.3.0)
7
+
8
+ GEM
9
+ remote: https://rubygems.org/
10
+ specs:
11
+ actionmailer (3.2.14)
12
+ actionpack (= 3.2.14)
13
+ mail (~> 2.5.4)
14
+ actionpack (3.2.14)
15
+ activemodel (= 3.2.14)
16
+ activesupport (= 3.2.14)
17
+ builder (~> 3.0.0)
18
+ erubis (~> 2.7.0)
19
+ journey (~> 1.0.4)
20
+ rack (~> 1.4.5)
21
+ rack-cache (~> 1.2)
22
+ rack-test (~> 0.6.1)
23
+ sprockets (~> 2.2.1)
24
+ activemodel (3.2.14)
25
+ activesupport (= 3.2.14)
26
+ builder (~> 3.0.0)
27
+ activerecord (3.2.14)
28
+ activemodel (= 3.2.14)
29
+ activesupport (= 3.2.14)
30
+ arel (~> 3.0.2)
31
+ tzinfo (~> 0.3.29)
32
+ activerecord-import (0.4.1)
33
+ activerecord (>= 3.0)
34
+ activeresource (3.2.14)
35
+ activemodel (= 3.2.14)
36
+ activesupport (= 3.2.14)
37
+ activesupport (3.2.14)
38
+ i18n (~> 0.6, >= 0.6.4)
39
+ multi_json (~> 1.0)
40
+ arel (3.0.2)
41
+ bson (1.9.2)
42
+ builder (3.0.4)
43
+ coderay (1.0.9)
44
+ colorize (0.5.8)
45
+ coveralls (0.6.7)
46
+ colorize
47
+ multi_json (~> 1.3)
48
+ rest-client
49
+ simplecov (>= 0.7)
50
+ thor
51
+ diff-lcs (1.2.4)
52
+ erubis (2.7.0)
53
+ ffi (1.9.0)
54
+ formatador (0.2.4)
55
+ guard (1.8.2)
56
+ formatador (>= 0.2.4)
57
+ listen (>= 1.0.0)
58
+ lumberjack (>= 1.0.2)
59
+ pry (>= 0.9.10)
60
+ thor (>= 0.14.6)
61
+ guard-rspec (3.0.2)
62
+ guard (>= 1.8)
63
+ rspec (~> 2.13)
64
+ hike (1.2.3)
65
+ i18n (0.6.5)
66
+ journey (1.0.4)
67
+ json (1.8.0)
68
+ listen (1.3.0)
69
+ rb-fsevent (>= 0.9.3)
70
+ rb-inotify (>= 0.9)
71
+ rb-kqueue (>= 0.2)
72
+ lumberjack (1.0.4)
73
+ mail (2.5.4)
74
+ mime-types (~> 1.16)
75
+ treetop (~> 1.4.8)
76
+ method_source (0.8.2)
77
+ mime-types (1.24)
78
+ mongo (1.9.2)
79
+ bson (~> 1.9.2)
80
+ mongoid (2.6.0)
81
+ activemodel (~> 3.1)
82
+ mongo (~> 1.7)
83
+ tzinfo (~> 0.3.22)
84
+ multi_json (1.7.9)
85
+ mysql2 (0.3.13)
86
+ polyglot (0.3.3)
87
+ pry (0.9.12.2)
88
+ coderay (~> 1.0.5)
89
+ method_source (~> 0.8)
90
+ slop (~> 3.4)
91
+ rack (1.4.5)
92
+ rack-cache (1.2)
93
+ rack (>= 0.4)
94
+ rack-ssl (1.3.3)
95
+ rack
96
+ rack-test (0.6.2)
97
+ rack (>= 1.0)
98
+ rails (3.2.14)
99
+ actionmailer (= 3.2.14)
100
+ actionpack (= 3.2.14)
101
+ activerecord (= 3.2.14)
102
+ activeresource (= 3.2.14)
103
+ activesupport (= 3.2.14)
104
+ bundler (~> 1.0)
105
+ railties (= 3.2.14)
106
+ railties (3.2.14)
107
+ actionpack (= 3.2.14)
108
+ activesupport (= 3.2.14)
109
+ rack-ssl (~> 1.3.2)
110
+ rake (>= 0.8.7)
111
+ rdoc (~> 3.4)
112
+ thor (>= 0.14.6, < 2.0)
113
+ rake (10.1.0)
114
+ rb-fsevent (0.9.3)
115
+ rb-inotify (0.9.1)
116
+ ffi (>= 0.5.0)
117
+ rb-kqueue (0.2.0)
118
+ ffi (>= 0.5.0)
119
+ rdoc (3.12.2)
120
+ json (~> 1.4)
121
+ rest-client (1.6.7)
122
+ mime-types (>= 1.16)
123
+ rspec (2.14.1)
124
+ rspec-core (~> 2.14.0)
125
+ rspec-expectations (~> 2.14.0)
126
+ rspec-mocks (~> 2.14.0)
127
+ rspec-core (2.14.5)
128
+ rspec-expectations (2.14.2)
129
+ diff-lcs (>= 1.1.3, < 2.0)
130
+ rspec-mocks (2.14.3)
131
+ simplecov (0.7.1)
132
+ multi_json (~> 1.0)
133
+ simplecov-html (~> 0.7.1)
134
+ simplecov-html (0.7.1)
135
+ slop (3.4.6)
136
+ sprockets (2.2.2)
137
+ hike (~> 1.2)
138
+ multi_json (~> 1.0)
139
+ rack (~> 1.0)
140
+ tilt (~> 1.1, != 1.3.0)
141
+ sqlite3 (1.3.8)
142
+ thor (0.18.1)
143
+ tilt (1.4.1)
144
+ treetop (1.4.15)
145
+ polyglot
146
+ polyglot (>= 0.3.1)
147
+ tzinfo (0.3.37)
148
+ uniform_notifier (1.3.0)
149
+
150
+ PLATFORMS
151
+ ruby
152
+
153
+ DEPENDENCIES
154
+ activerecord-import
155
+ bullet!
156
+ coveralls
157
+ guard
158
+ guard-rspec
159
+ mongoid (= 2.6.0)
160
+ mysql2
161
+ rails
162
+ rspec
163
+ sqlite3
@@ -0,0 +1,15 @@
1
+ source "https://rubygems.org"
2
+
3
+ gemspec
4
+
5
+ gem 'rails'
6
+ gem 'sqlite3'
7
+ gem 'mysql2'
8
+ gem 'activerecord-import'
9
+ gem 'mongoid', '2.7.1'
10
+
11
+ gem "rspec"
12
+ gem "guard"
13
+ gem "guard-rspec"
14
+
15
+ gem 'coveralls', require: false
@@ -0,0 +1,163 @@
1
+ PATH
2
+ remote: .
3
+ specs:
4
+ bullet (4.7.0)
5
+ activesupport
6
+ uniform_notifier (>= 1.3.0)
7
+
8
+ GEM
9
+ remote: https://rubygems.org/
10
+ specs:
11
+ actionmailer (3.2.14)
12
+ actionpack (= 3.2.14)
13
+ mail (~> 2.5.4)
14
+ actionpack (3.2.14)
15
+ activemodel (= 3.2.14)
16
+ activesupport (= 3.2.14)
17
+ builder (~> 3.0.0)
18
+ erubis (~> 2.7.0)
19
+ journey (~> 1.0.4)
20
+ rack (~> 1.4.5)
21
+ rack-cache (~> 1.2)
22
+ rack-test (~> 0.6.1)
23
+ sprockets (~> 2.2.1)
24
+ activemodel (3.2.14)
25
+ activesupport (= 3.2.14)
26
+ builder (~> 3.0.0)
27
+ activerecord (3.2.14)
28
+ activemodel (= 3.2.14)
29
+ activesupport (= 3.2.14)
30
+ arel (~> 3.0.2)
31
+ tzinfo (~> 0.3.29)
32
+ activerecord-import (0.4.1)
33
+ activerecord (>= 3.0)
34
+ activeresource (3.2.14)
35
+ activemodel (= 3.2.14)
36
+ activesupport (= 3.2.14)
37
+ activesupport (3.2.14)
38
+ i18n (~> 0.6, >= 0.6.4)
39
+ multi_json (~> 1.0)
40
+ arel (3.0.2)
41
+ bson (1.9.2)
42
+ builder (3.0.4)
43
+ coderay (1.0.9)
44
+ colorize (0.5.8)
45
+ coveralls (0.6.7)
46
+ colorize
47
+ multi_json (~> 1.3)
48
+ rest-client
49
+ simplecov (>= 0.7)
50
+ thor
51
+ diff-lcs (1.2.4)
52
+ erubis (2.7.0)
53
+ ffi (1.9.0)
54
+ formatador (0.2.4)
55
+ guard (1.8.2)
56
+ formatador (>= 0.2.4)
57
+ listen (>= 1.0.0)
58
+ lumberjack (>= 1.0.2)
59
+ pry (>= 0.9.10)
60
+ thor (>= 0.14.6)
61
+ guard-rspec (3.0.2)
62
+ guard (>= 1.8)
63
+ rspec (~> 2.13)
64
+ hike (1.2.3)
65
+ i18n (0.6.5)
66
+ journey (1.0.4)
67
+ json (1.8.0)
68
+ listen (1.3.0)
69
+ rb-fsevent (>= 0.9.3)
70
+ rb-inotify (>= 0.9)
71
+ rb-kqueue (>= 0.2)
72
+ lumberjack (1.0.4)
73
+ mail (2.5.4)
74
+ mime-types (~> 1.16)
75
+ treetop (~> 1.4.8)
76
+ method_source (0.8.2)
77
+ mime-types (1.24)
78
+ mongo (1.9.2)
79
+ bson (~> 1.9.2)
80
+ mongoid (2.7.1)
81
+ activemodel (~> 3.1)
82
+ mongo (~> 1.8)
83
+ tzinfo (~> 0.3.22)
84
+ multi_json (1.7.9)
85
+ mysql2 (0.3.13)
86
+ polyglot (0.3.3)
87
+ pry (0.9.12.2)
88
+ coderay (~> 1.0.5)
89
+ method_source (~> 0.8)
90
+ slop (~> 3.4)
91
+ rack (1.4.5)
92
+ rack-cache (1.2)
93
+ rack (>= 0.4)
94
+ rack-ssl (1.3.3)
95
+ rack
96
+ rack-test (0.6.2)
97
+ rack (>= 1.0)
98
+ rails (3.2.14)
99
+ actionmailer (= 3.2.14)
100
+ actionpack (= 3.2.14)
101
+ activerecord (= 3.2.14)
102
+ activeresource (= 3.2.14)
103
+ activesupport (= 3.2.14)
104
+ bundler (~> 1.0)
105
+ railties (= 3.2.14)
106
+ railties (3.2.14)
107
+ actionpack (= 3.2.14)
108
+ activesupport (= 3.2.14)
109
+ rack-ssl (~> 1.3.2)
110
+ rake (>= 0.8.7)
111
+ rdoc (~> 3.4)
112
+ thor (>= 0.14.6, < 2.0)
113
+ rake (10.1.0)
114
+ rb-fsevent (0.9.3)
115
+ rb-inotify (0.9.1)
116
+ ffi (>= 0.5.0)
117
+ rb-kqueue (0.2.0)
118
+ ffi (>= 0.5.0)
119
+ rdoc (3.12.2)
120
+ json (~> 1.4)
121
+ rest-client (1.6.7)
122
+ mime-types (>= 1.16)
123
+ rspec (2.14.1)
124
+ rspec-core (~> 2.14.0)
125
+ rspec-expectations (~> 2.14.0)
126
+ rspec-mocks (~> 2.14.0)
127
+ rspec-core (2.14.5)
128
+ rspec-expectations (2.14.2)
129
+ diff-lcs (>= 1.1.3, < 2.0)
130
+ rspec-mocks (2.14.3)
131
+ simplecov (0.7.1)
132
+ multi_json (~> 1.0)
133
+ simplecov-html (~> 0.7.1)
134
+ simplecov-html (0.7.1)
135
+ slop (3.4.6)
136
+ sprockets (2.2.2)
137
+ hike (~> 1.2)
138
+ multi_json (~> 1.0)
139
+ rack (~> 1.0)
140
+ tilt (~> 1.1, != 1.3.0)
141
+ sqlite3 (1.3.8)
142
+ thor (0.18.1)
143
+ tilt (1.4.1)
144
+ treetop (1.4.15)
145
+ polyglot
146
+ polyglot (>= 0.3.1)
147
+ tzinfo (0.3.37)
148
+ uniform_notifier (1.3.0)
149
+
150
+ PLATFORMS
151
+ ruby
152
+
153
+ DEPENDENCIES
154
+ activerecord-import
155
+ bullet!
156
+ coveralls
157
+ guard
158
+ guard-rspec
159
+ mongoid (= 2.7.1)
160
+ mysql2
161
+ rails
162
+ rspec
163
+ sqlite3
@@ -0,0 +1,15 @@
1
+ source "https://rubygems.org"
2
+
3
+ gemspec
4
+
5
+ gem 'rails', '~> 3.2'
6
+ gem 'sqlite3'
7
+ gem 'mysql2'
8
+ gem 'activerecord-import'
9
+ gem 'mongoid', '2.8.1'
10
+
11
+ gem "rspec"
12
+ gem "guard"
13
+ gem "guard-rspec"
14
+
15
+ gem 'coveralls', require: false
@@ -0,0 +1,166 @@
1
+ PATH
2
+ remote: .
3
+ specs:
4
+ bullet (4.7.0)
5
+ activesupport
6
+ uniform_notifier (>= 1.3.0)
7
+
8
+ GEM
9
+ remote: https://rubygems.org/
10
+ specs:
11
+ actionmailer (3.2.15)
12
+ actionpack (= 3.2.15)
13
+ mail (~> 2.5.4)
14
+ actionpack (3.2.15)
15
+ activemodel (= 3.2.15)
16
+ activesupport (= 3.2.15)
17
+ builder (~> 3.0.0)
18
+ erubis (~> 2.7.0)
19
+ journey (~> 1.0.4)
20
+ rack (~> 1.4.5)
21
+ rack-cache (~> 1.2)
22
+ rack-test (~> 0.6.1)
23
+ sprockets (~> 2.2.1)
24
+ activemodel (3.2.15)
25
+ activesupport (= 3.2.15)
26
+ builder (~> 3.0.0)
27
+ activerecord (3.2.15)
28
+ activemodel (= 3.2.15)
29
+ activesupport (= 3.2.15)
30
+ arel (~> 3.0.2)
31
+ tzinfo (~> 0.3.29)
32
+ activerecord-import (0.4.1)
33
+ activerecord (>= 3.0)
34
+ activeresource (3.2.15)
35
+ activemodel (= 3.2.15)
36
+ activesupport (= 3.2.15)
37
+ activesupport (3.2.15)
38
+ i18n (~> 0.6, >= 0.6.4)
39
+ multi_json (~> 1.0)
40
+ arel (3.0.2)
41
+ bson (1.9.2)
42
+ builder (3.0.4)
43
+ celluloid (0.15.2)
44
+ timers (~> 1.1.0)
45
+ coderay (1.0.9)
46
+ coveralls (0.7.0)
47
+ multi_json (~> 1.3)
48
+ rest-client
49
+ simplecov (>= 0.7)
50
+ term-ansicolor
51
+ thor
52
+ diff-lcs (1.2.4)
53
+ erubis (2.7.0)
54
+ ffi (1.9.3)
55
+ formatador (0.2.4)
56
+ guard (2.2.2)
57
+ formatador (>= 0.2.4)
58
+ listen (~> 2.1)
59
+ lumberjack (~> 1.0)
60
+ pry (>= 0.9.12)
61
+ thor (>= 0.18.1)
62
+ guard-rspec (4.0.3)
63
+ guard (>= 2.1.1)
64
+ rspec (~> 2.14)
65
+ hike (1.2.3)
66
+ i18n (0.6.5)
67
+ journey (1.0.4)
68
+ json (1.8.1)
69
+ listen (2.2.0)
70
+ celluloid (>= 0.15.2)
71
+ rb-fsevent (>= 0.9.3)
72
+ rb-inotify (>= 0.9)
73
+ lumberjack (1.0.4)
74
+ mail (2.5.4)
75
+ mime-types (~> 1.16)
76
+ treetop (~> 1.4.8)
77
+ method_source (0.8.2)
78
+ mime-types (1.25)
79
+ mongo (1.9.2)
80
+ bson (~> 1.9.2)
81
+ mongoid (2.8.1)
82
+ activemodel (~> 3.1)
83
+ mongo (~> 1.9)
84
+ tzinfo (~> 0.3.22)
85
+ multi_json (1.8.2)
86
+ mysql2 (0.3.13)
87
+ polyglot (0.3.3)
88
+ pry (0.9.12.2)
89
+ coderay (~> 1.0.5)
90
+ method_source (~> 0.8)
91
+ slop (~> 3.4)
92
+ rack (1.4.5)
93
+ rack-cache (1.2)
94
+ rack (>= 0.4)
95
+ rack-ssl (1.3.3)
96
+ rack
97
+ rack-test (0.6.2)
98
+ rack (>= 1.0)
99
+ rails (3.2.15)
100
+ actionmailer (= 3.2.15)
101
+ actionpack (= 3.2.15)
102
+ activerecord (= 3.2.15)
103
+ activeresource (= 3.2.15)
104
+ activesupport (= 3.2.15)
105
+ bundler (~> 1.0)
106
+ railties (= 3.2.15)
107
+ railties (3.2.15)
108
+ actionpack (= 3.2.15)
109
+ activesupport (= 3.2.15)
110
+ rack-ssl (~> 1.3.2)
111
+ rake (>= 0.8.7)
112
+ rdoc (~> 3.4)
113
+ thor (>= 0.14.6, < 2.0)
114
+ rake (10.1.0)
115
+ rb-fsevent (0.9.3)
116
+ rb-inotify (0.9.2)
117
+ ffi (>= 0.5.0)
118
+ rdoc (3.12.2)
119
+ json (~> 1.4)
120
+ rest-client (1.6.7)
121
+ mime-types (>= 1.16)
122
+ rspec (2.14.1)
123
+ rspec-core (~> 2.14.0)
124
+ rspec-expectations (~> 2.14.0)
125
+ rspec-mocks (~> 2.14.0)
126
+ rspec-core (2.14.7)
127
+ rspec-expectations (2.14.3)
128
+ diff-lcs (>= 1.1.3, < 2.0)
129
+ rspec-mocks (2.14.4)
130
+ simplecov (0.7.1)
131
+ multi_json (~> 1.0)
132
+ simplecov-html (~> 0.7.1)
133
+ simplecov-html (0.7.1)
134
+ slop (3.4.6)
135
+ sprockets (2.2.2)
136
+ hike (~> 1.2)
137
+ multi_json (~> 1.0)
138
+ rack (~> 1.0)
139
+ tilt (~> 1.1, != 1.3.0)
140
+ sqlite3 (1.3.8)
141
+ term-ansicolor (1.2.2)
142
+ tins (~> 0.8)
143
+ thor (0.18.1)
144
+ tilt (1.4.1)
145
+ timers (1.1.0)
146
+ tins (0.12.0)
147
+ treetop (1.4.15)
148
+ polyglot
149
+ polyglot (>= 0.3.1)
150
+ tzinfo (0.3.38)
151
+ uniform_notifier (1.3.0)
152
+
153
+ PLATFORMS
154
+ ruby
155
+
156
+ DEPENDENCIES
157
+ activerecord-import
158
+ bullet!
159
+ coveralls
160
+ guard
161
+ guard-rspec
162
+ mongoid (= 2.8.1)
163
+ mysql2
164
+ rails (~> 3.2)
165
+ rspec
166
+ sqlite3