bullet_instructure 4.0.2
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.
- checksums.yaml +7 -0
- data/.gitignore +14 -0
- data/.rspec +2 -0
- data/.ruby-version +1 -0
- data/.travis.yml +20 -0
- data/CHANGELOG.md +75 -0
- data/Gemfile +19 -0
- data/Gemfile.mongoid +14 -0
- data/Gemfile.mongoid-2.4 +19 -0
- data/Gemfile.mongoid-2.5 +19 -0
- data/Gemfile.mongoid-2.6 +19 -0
- data/Gemfile.mongoid-2.7 +19 -0
- data/Gemfile.mongoid-2.8 +19 -0
- data/Gemfile.mongoid-3.0 +19 -0
- data/Gemfile.mongoid-3.1 +19 -0
- data/Gemfile.mongoid-4.0 +19 -0
- data/Gemfile.rails-3.0 +19 -0
- data/Gemfile.rails-3.1 +19 -0
- data/Gemfile.rails-3.2 +19 -0
- data/Gemfile.rails-4.0 +19 -0
- data/Gemfile.rails-4.1 +19 -0
- data/Guardfile +8 -0
- data/Hacking.md +74 -0
- data/MIT-LICENSE +20 -0
- data/README.md +428 -0
- data/Rakefile +52 -0
- data/bullet_instructure.gemspec +27 -0
- data/lib/bullet.rb +196 -0
- data/lib/bullet/active_record3.rb +148 -0
- data/lib/bullet/active_record3x.rb +128 -0
- data/lib/bullet/active_record4.rb +128 -0
- data/lib/bullet/active_record41.rb +121 -0
- data/lib/bullet/dependency.rb +81 -0
- data/lib/bullet/detector.rb +9 -0
- data/lib/bullet/detector/association.rb +67 -0
- data/lib/bullet/detector/base.rb +6 -0
- data/lib/bullet/detector/counter_cache.rb +59 -0
- data/lib/bullet/detector/n_plus_one_query.rb +89 -0
- data/lib/bullet/detector/unused_eager_loading.rb +84 -0
- data/lib/bullet/ext/object.rb +9 -0
- data/lib/bullet/ext/string.rb +5 -0
- data/lib/bullet/mongoid2x.rb +56 -0
- data/lib/bullet/mongoid3x.rb +56 -0
- data/lib/bullet/mongoid4x.rb +56 -0
- data/lib/bullet/notification.rb +10 -0
- data/lib/bullet/notification/base.rb +97 -0
- data/lib/bullet/notification/counter_cache.rb +13 -0
- data/lib/bullet/notification/n_plus_one_query.rb +28 -0
- data/lib/bullet/notification/unused_eager_loading.rb +13 -0
- data/lib/bullet/notification_collector.rb +24 -0
- data/lib/bullet/rack.rb +81 -0
- data/lib/bullet/registry.rb +7 -0
- data/lib/bullet/registry/association.rb +13 -0
- data/lib/bullet/registry/base.rb +40 -0
- data/lib/bullet/registry/object.rb +13 -0
- data/lib/bullet/version.rb +4 -0
- data/perf/benchmark.rb +121 -0
- data/rails/init.rb +1 -0
- data/spec/bullet/detector/association_spec.rb +26 -0
- data/spec/bullet/detector/base_spec.rb +8 -0
- data/spec/bullet/detector/counter_cache_spec.rb +56 -0
- data/spec/bullet/detector/n_plus_one_query_spec.rb +138 -0
- data/spec/bullet/detector/unused_eager_loading_spec.rb +88 -0
- data/spec/bullet/ext/object_spec.rb +17 -0
- data/spec/bullet/ext/string_spec.rb +13 -0
- data/spec/bullet/notification/base_spec.rb +83 -0
- data/spec/bullet/notification/counter_cache_spec.rb +12 -0
- data/spec/bullet/notification/n_plus_one_query_spec.rb +14 -0
- data/spec/bullet/notification/unused_eager_loading_spec.rb +12 -0
- data/spec/bullet/notification_collector_spec.rb +32 -0
- data/spec/bullet/rack_spec.rb +97 -0
- data/spec/bullet/registry/association_spec.rb +26 -0
- data/spec/bullet/registry/base_spec.rb +44 -0
- data/spec/bullet/registry/object_spec.rb +24 -0
- data/spec/bullet_spec.rb +41 -0
- data/spec/integration/active_record3/association_spec.rb +651 -0
- data/spec/integration/active_record4/association_spec.rb +649 -0
- data/spec/integration/counter_cache_spec.rb +63 -0
- data/spec/integration/mongoid/association_spec.rb +258 -0
- data/spec/models/address.rb +3 -0
- data/spec/models/author.rb +3 -0
- data/spec/models/base_user.rb +5 -0
- data/spec/models/category.rb +7 -0
- data/spec/models/city.rb +3 -0
- data/spec/models/client.rb +4 -0
- data/spec/models/comment.rb +4 -0
- data/spec/models/company.rb +3 -0
- data/spec/models/country.rb +3 -0
- data/spec/models/document.rb +5 -0
- data/spec/models/entry.rb +3 -0
- data/spec/models/firm.rb +4 -0
- data/spec/models/folder.rb +2 -0
- data/spec/models/mongoid/address.rb +7 -0
- data/spec/models/mongoid/category.rb +8 -0
- data/spec/models/mongoid/comment.rb +7 -0
- data/spec/models/mongoid/company.rb +7 -0
- data/spec/models/mongoid/entry.rb +7 -0
- data/spec/models/mongoid/post.rb +12 -0
- data/spec/models/mongoid/user.rb +5 -0
- data/spec/models/newspaper.rb +3 -0
- data/spec/models/page.rb +2 -0
- data/spec/models/person.rb +3 -0
- data/spec/models/pet.rb +3 -0
- data/spec/models/post.rb +10 -0
- data/spec/models/relationship.rb +4 -0
- data/spec/models/student.rb +3 -0
- data/spec/models/submission.rb +4 -0
- data/spec/models/teacher.rb +3 -0
- data/spec/models/user.rb +4 -0
- data/spec/models/writer.rb +2 -0
- data/spec/spec_helper.rb +103 -0
- data/spec/support/bullet_ext.rb +55 -0
- data/spec/support/mongo_seed.rb +65 -0
- data/spec/support/rack_double.rb +55 -0
- data/spec/support/sqlite_seed.rb +229 -0
- data/tasks/bullet_tasks.rake +9 -0
- data/test.sh +15 -0
- metadata +246 -0
data/test.sh
ADDED
@@ -0,0 +1,15 @@
|
|
1
|
+
#bundle update rails && bundle exec rspec spec
|
2
|
+
#BUNDLE_GEMFILE=Gemfile.mongoid bundle update mongoid && BUNDLE_GEMFILE=Gemfile.mongoid bundle exec rspec spec
|
3
|
+
BUNDLE_GEMFILE=Gemfile.rails-4.1 bundle && BUNDLE_GEMFILE=Gemfile.rails-4.1 bundle exec rspec spec
|
4
|
+
BUNDLE_GEMFILE=Gemfile.rails-4.0 bundle && BUNDLE_GEMFILE=Gemfile.rails-4.0 bundle exec rspec spec
|
5
|
+
BUNDLE_GEMFILE=Gemfile.rails-3.2 bundle && BUNDLE_GEMFILE=Gemfile.rails-3.2 bundle exec rspec spec
|
6
|
+
BUNDLE_GEMFILE=Gemfile.rails-3.1 bundle && BUNDLE_GEMFILE=Gemfile.rails-3.1 bundle exec rspec spec
|
7
|
+
BUNDLE_GEMFILE=Gemfile.rails-3.0 bundle && BUNDLE_GEMFILE=Gemfile.rails-3.0 bundle exec rspec spec
|
8
|
+
BUNDLE_GEMFILE=Gemfile.mongoid-4.0 bundle && BUNDLE_GEMFILE=Gemfile.mongoid-4.0 bundle exec rspec spec
|
9
|
+
BUNDLE_GEMFILE=Gemfile.mongoid-3.1 bundle && BUNDLE_GEMFILE=Gemfile.mongoid-3.1 bundle exec rspec spec
|
10
|
+
BUNDLE_GEMFILE=Gemfile.mongoid-3.0 bundle && BUNDLE_GEMFILE=Gemfile.mongoid-3.0 bundle exec rspec spec
|
11
|
+
BUNDLE_GEMFILE=Gemfile.mongoid-2.8 bundle && BUNDLE_GEMFILE=Gemfile.mongoid-2.8 bundle exec rspec spec
|
12
|
+
BUNDLE_GEMFILE=Gemfile.mongoid-2.7 bundle && BUNDLE_GEMFILE=Gemfile.mongoid-2.7 bundle exec rspec spec
|
13
|
+
BUNDLE_GEMFILE=Gemfile.mongoid-2.6 bundle && BUNDLE_GEMFILE=Gemfile.mongoid-2.6 bundle exec rspec spec
|
14
|
+
BUNDLE_GEMFILE=Gemfile.mongoid-2.5 bundle && BUNDLE_GEMFILE=Gemfile.mongoid-2.5 bundle exec rspec spec
|
15
|
+
BUNDLE_GEMFILE=Gemfile.mongoid-2.4 bundle && BUNDLE_GEMFILE=Gemfile.mongoid-2.4 bundle exec rspec spec
|
metadata
ADDED
@@ -0,0 +1,246 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: bullet_instructure
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 4.0.2
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Richard Huang
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
date: 2014-06-30 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: activesupport
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - '>='
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: 3.0.0
|
20
|
+
type: :runtime
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - '>='
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: 3.0.0
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: uniform_notifier
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - '>='
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: 1.6.0
|
34
|
+
type: :runtime
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - '>='
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: 1.6.0
|
41
|
+
description: help to kill N+1 queries and unused eager loading, pretty formatter for
|
42
|
+
Instructure.
|
43
|
+
email:
|
44
|
+
- flyerhzm@gmail.com
|
45
|
+
executables: []
|
46
|
+
extensions: []
|
47
|
+
extra_rdoc_files: []
|
48
|
+
files:
|
49
|
+
- .gitignore
|
50
|
+
- .rspec
|
51
|
+
- .ruby-version
|
52
|
+
- .travis.yml
|
53
|
+
- CHANGELOG.md
|
54
|
+
- Gemfile
|
55
|
+
- Gemfile.mongoid
|
56
|
+
- Gemfile.mongoid-2.4
|
57
|
+
- Gemfile.mongoid-2.5
|
58
|
+
- Gemfile.mongoid-2.6
|
59
|
+
- Gemfile.mongoid-2.7
|
60
|
+
- Gemfile.mongoid-2.8
|
61
|
+
- Gemfile.mongoid-3.0
|
62
|
+
- Gemfile.mongoid-3.1
|
63
|
+
- Gemfile.mongoid-4.0
|
64
|
+
- Gemfile.rails-3.0
|
65
|
+
- Gemfile.rails-3.1
|
66
|
+
- Gemfile.rails-3.2
|
67
|
+
- Gemfile.rails-4.0
|
68
|
+
- Gemfile.rails-4.1
|
69
|
+
- Guardfile
|
70
|
+
- Hacking.md
|
71
|
+
- MIT-LICENSE
|
72
|
+
- README.md
|
73
|
+
- Rakefile
|
74
|
+
- bullet_instructure.gemspec
|
75
|
+
- lib/bullet.rb
|
76
|
+
- lib/bullet/active_record3.rb
|
77
|
+
- lib/bullet/active_record3x.rb
|
78
|
+
- lib/bullet/active_record4.rb
|
79
|
+
- lib/bullet/active_record41.rb
|
80
|
+
- lib/bullet/dependency.rb
|
81
|
+
- lib/bullet/detector.rb
|
82
|
+
- lib/bullet/detector/association.rb
|
83
|
+
- lib/bullet/detector/base.rb
|
84
|
+
- lib/bullet/detector/counter_cache.rb
|
85
|
+
- lib/bullet/detector/n_plus_one_query.rb
|
86
|
+
- lib/bullet/detector/unused_eager_loading.rb
|
87
|
+
- lib/bullet/ext/object.rb
|
88
|
+
- lib/bullet/ext/string.rb
|
89
|
+
- lib/bullet/mongoid2x.rb
|
90
|
+
- lib/bullet/mongoid3x.rb
|
91
|
+
- lib/bullet/mongoid4x.rb
|
92
|
+
- lib/bullet/notification.rb
|
93
|
+
- lib/bullet/notification/base.rb
|
94
|
+
- lib/bullet/notification/counter_cache.rb
|
95
|
+
- lib/bullet/notification/n_plus_one_query.rb
|
96
|
+
- lib/bullet/notification/unused_eager_loading.rb
|
97
|
+
- lib/bullet/notification_collector.rb
|
98
|
+
- lib/bullet/rack.rb
|
99
|
+
- lib/bullet/registry.rb
|
100
|
+
- lib/bullet/registry/association.rb
|
101
|
+
- lib/bullet/registry/base.rb
|
102
|
+
- lib/bullet/registry/object.rb
|
103
|
+
- lib/bullet/version.rb
|
104
|
+
- perf/benchmark.rb
|
105
|
+
- rails/init.rb
|
106
|
+
- spec/bullet/detector/association_spec.rb
|
107
|
+
- spec/bullet/detector/base_spec.rb
|
108
|
+
- spec/bullet/detector/counter_cache_spec.rb
|
109
|
+
- spec/bullet/detector/n_plus_one_query_spec.rb
|
110
|
+
- spec/bullet/detector/unused_eager_loading_spec.rb
|
111
|
+
- spec/bullet/ext/object_spec.rb
|
112
|
+
- spec/bullet/ext/string_spec.rb
|
113
|
+
- spec/bullet/notification/base_spec.rb
|
114
|
+
- spec/bullet/notification/counter_cache_spec.rb
|
115
|
+
- spec/bullet/notification/n_plus_one_query_spec.rb
|
116
|
+
- spec/bullet/notification/unused_eager_loading_spec.rb
|
117
|
+
- spec/bullet/notification_collector_spec.rb
|
118
|
+
- spec/bullet/rack_spec.rb
|
119
|
+
- spec/bullet/registry/association_spec.rb
|
120
|
+
- spec/bullet/registry/base_spec.rb
|
121
|
+
- spec/bullet/registry/object_spec.rb
|
122
|
+
- spec/bullet_spec.rb
|
123
|
+
- spec/integration/active_record3/association_spec.rb
|
124
|
+
- spec/integration/active_record4/association_spec.rb
|
125
|
+
- spec/integration/counter_cache_spec.rb
|
126
|
+
- spec/integration/mongoid/association_spec.rb
|
127
|
+
- spec/models/address.rb
|
128
|
+
- spec/models/author.rb
|
129
|
+
- spec/models/base_user.rb
|
130
|
+
- spec/models/category.rb
|
131
|
+
- spec/models/city.rb
|
132
|
+
- spec/models/client.rb
|
133
|
+
- spec/models/comment.rb
|
134
|
+
- spec/models/company.rb
|
135
|
+
- spec/models/country.rb
|
136
|
+
- spec/models/document.rb
|
137
|
+
- spec/models/entry.rb
|
138
|
+
- spec/models/firm.rb
|
139
|
+
- spec/models/folder.rb
|
140
|
+
- spec/models/mongoid/address.rb
|
141
|
+
- spec/models/mongoid/category.rb
|
142
|
+
- spec/models/mongoid/comment.rb
|
143
|
+
- spec/models/mongoid/company.rb
|
144
|
+
- spec/models/mongoid/entry.rb
|
145
|
+
- spec/models/mongoid/post.rb
|
146
|
+
- spec/models/mongoid/user.rb
|
147
|
+
- spec/models/newspaper.rb
|
148
|
+
- spec/models/page.rb
|
149
|
+
- spec/models/person.rb
|
150
|
+
- spec/models/pet.rb
|
151
|
+
- spec/models/post.rb
|
152
|
+
- spec/models/relationship.rb
|
153
|
+
- spec/models/student.rb
|
154
|
+
- spec/models/submission.rb
|
155
|
+
- spec/models/teacher.rb
|
156
|
+
- spec/models/user.rb
|
157
|
+
- spec/models/writer.rb
|
158
|
+
- spec/spec_helper.rb
|
159
|
+
- spec/support/bullet_ext.rb
|
160
|
+
- spec/support/mongo_seed.rb
|
161
|
+
- spec/support/rack_double.rb
|
162
|
+
- spec/support/sqlite_seed.rb
|
163
|
+
- tasks/bullet_tasks.rake
|
164
|
+
- test.sh
|
165
|
+
homepage: http://github.com/flyerhzm/bullet
|
166
|
+
licenses:
|
167
|
+
- MIT
|
168
|
+
metadata: {}
|
169
|
+
post_install_message:
|
170
|
+
rdoc_options: []
|
171
|
+
require_paths:
|
172
|
+
- lib
|
173
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
174
|
+
requirements:
|
175
|
+
- - '>='
|
176
|
+
- !ruby/object:Gem::Version
|
177
|
+
version: '0'
|
178
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
179
|
+
requirements:
|
180
|
+
- - '>='
|
181
|
+
- !ruby/object:Gem::Version
|
182
|
+
version: 1.3.6
|
183
|
+
requirements: []
|
184
|
+
rubyforge_project:
|
185
|
+
rubygems_version: 2.0.3
|
186
|
+
signing_key:
|
187
|
+
specification_version: 4
|
188
|
+
summary: help to kill N+1 queries and unused eager loading, pretty formatter for Instructure.
|
189
|
+
test_files:
|
190
|
+
- spec/bullet/detector/association_spec.rb
|
191
|
+
- spec/bullet/detector/base_spec.rb
|
192
|
+
- spec/bullet/detector/counter_cache_spec.rb
|
193
|
+
- spec/bullet/detector/n_plus_one_query_spec.rb
|
194
|
+
- spec/bullet/detector/unused_eager_loading_spec.rb
|
195
|
+
- spec/bullet/ext/object_spec.rb
|
196
|
+
- spec/bullet/ext/string_spec.rb
|
197
|
+
- spec/bullet/notification/base_spec.rb
|
198
|
+
- spec/bullet/notification/counter_cache_spec.rb
|
199
|
+
- spec/bullet/notification/n_plus_one_query_spec.rb
|
200
|
+
- spec/bullet/notification/unused_eager_loading_spec.rb
|
201
|
+
- spec/bullet/notification_collector_spec.rb
|
202
|
+
- spec/bullet/rack_spec.rb
|
203
|
+
- spec/bullet/registry/association_spec.rb
|
204
|
+
- spec/bullet/registry/base_spec.rb
|
205
|
+
- spec/bullet/registry/object_spec.rb
|
206
|
+
- spec/bullet_spec.rb
|
207
|
+
- spec/integration/active_record3/association_spec.rb
|
208
|
+
- spec/integration/active_record4/association_spec.rb
|
209
|
+
- spec/integration/counter_cache_spec.rb
|
210
|
+
- spec/integration/mongoid/association_spec.rb
|
211
|
+
- spec/models/address.rb
|
212
|
+
- spec/models/author.rb
|
213
|
+
- spec/models/base_user.rb
|
214
|
+
- spec/models/category.rb
|
215
|
+
- spec/models/city.rb
|
216
|
+
- spec/models/client.rb
|
217
|
+
- spec/models/comment.rb
|
218
|
+
- spec/models/company.rb
|
219
|
+
- spec/models/country.rb
|
220
|
+
- spec/models/document.rb
|
221
|
+
- spec/models/entry.rb
|
222
|
+
- spec/models/firm.rb
|
223
|
+
- spec/models/folder.rb
|
224
|
+
- spec/models/mongoid/address.rb
|
225
|
+
- spec/models/mongoid/category.rb
|
226
|
+
- spec/models/mongoid/comment.rb
|
227
|
+
- spec/models/mongoid/company.rb
|
228
|
+
- spec/models/mongoid/entry.rb
|
229
|
+
- spec/models/mongoid/post.rb
|
230
|
+
- spec/models/mongoid/user.rb
|
231
|
+
- spec/models/newspaper.rb
|
232
|
+
- spec/models/page.rb
|
233
|
+
- spec/models/person.rb
|
234
|
+
- spec/models/pet.rb
|
235
|
+
- spec/models/post.rb
|
236
|
+
- spec/models/relationship.rb
|
237
|
+
- spec/models/student.rb
|
238
|
+
- spec/models/submission.rb
|
239
|
+
- spec/models/teacher.rb
|
240
|
+
- spec/models/user.rb
|
241
|
+
- spec/models/writer.rb
|
242
|
+
- spec/spec_helper.rb
|
243
|
+
- spec/support/bullet_ext.rb
|
244
|
+
- spec/support/mongo_seed.rb
|
245
|
+
- spec/support/rack_double.rb
|
246
|
+
- spec/support/sqlite_seed.rb
|