ddtrace 0.39.0 → 0.40.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (36) hide show
  1. checksums.yaml +4 -4
  2. data/.circleci/config.yml +56 -0
  3. data/.gitlab-ci.yml +1 -0
  4. data/.simplecov +38 -0
  5. data/Appraisals +87 -1
  6. data/CHANGELOG.md +63 -1
  7. data/Rakefile +500 -465
  8. data/ddtrace.gemspec +1 -0
  9. data/docs/DevelopmentGuide.md +16 -0
  10. data/docs/GettingStarted.md +49 -32
  11. data/lib/ddtrace.rb +1 -0
  12. data/lib/ddtrace/configuration.rb +36 -5
  13. data/lib/ddtrace/configuration/components.rb +4 -7
  14. data/lib/ddtrace/contrib/action_pack/action_controller/instrumentation.rb +0 -7
  15. data/lib/ddtrace/contrib/que/configuration/settings.rb +42 -0
  16. data/lib/ddtrace/contrib/que/ext.rb +30 -0
  17. data/lib/ddtrace/contrib/que/integration.rb +42 -0
  18. data/lib/ddtrace/contrib/que/patcher.rb +24 -0
  19. data/lib/ddtrace/contrib/que/tracer.rb +56 -0
  20. data/lib/ddtrace/contrib/racecar/events.rb +2 -0
  21. data/lib/ddtrace/contrib/racecar/events/consume.rb +27 -0
  22. data/lib/ddtrace/contrib/racecar/ext.rb +1 -0
  23. data/lib/ddtrace/contrib/rack/middlewares.rb +2 -0
  24. data/lib/ddtrace/contrib/rails/configuration/settings.rb +5 -0
  25. data/lib/ddtrace/contrib/rails/ext.rb +1 -0
  26. data/lib/ddtrace/contrib/rails/log_injection.rb +81 -0
  27. data/lib/ddtrace/contrib/rails/middlewares.rb +7 -2
  28. data/lib/ddtrace/contrib/rails/patcher.rb +15 -0
  29. data/lib/ddtrace/contrib/sinatra/env.rb +5 -4
  30. data/lib/ddtrace/contrib/sinatra/tracer.rb +21 -42
  31. data/lib/ddtrace/contrib/sinatra/tracer_middleware.rb +50 -23
  32. data/lib/ddtrace/version.rb +1 -1
  33. data/lib/ddtrace/workers/async.rb +2 -2
  34. data/lib/ddtrace/workers/loop.rb +1 -1
  35. data/lib/ddtrace/workers/polling.rb +1 -1
  36. metadata +67 -31
@@ -2,6 +2,67 @@
2
2
 
3
3
  ## [Unreleased]
4
4
 
5
+ ## [0.40.0] - 2020-09-08
6
+
7
+ Release notes: https://github.com/DataDog/dd-trace-rb/releases/tag/v0.40.0
8
+
9
+ Git diff: https://github.com/DataDog/dd-trace-rb/compare/v0.39.0...v0.40.0
10
+
11
+ ### Added
12
+
13
+ - Rails `log_injection` option to auto enable log correlation (#1157)
14
+ - Que integration (#1141, #1146) (@hs-bguven)
15
+ - `Components#startup!` hook (#1151)
16
+ - Code coverage report (#1159)
17
+ - Every commit now has a `coverage` CI step that contains the code coverage report. This report can be found in the `Artifacts` tab of that CI step, under `coverage/index.html`.
18
+
19
+ ### Changed
20
+
21
+ - Use a single top level span for Racecar consumers (#1150) (@dasch)
22
+
23
+ ### Fixed
24
+
25
+ - Sinatra nested modular applications possibly leaking spans (#1035, #1145)
26
+
27
+ * **BREAKING** for nested modular Sinatra applications only:
28
+ ```ruby
29
+ class Nested < Sinatra::Base
30
+ end
31
+
32
+ class TopLevel < Sinatra::Base
33
+ use Nested # Nesting happens here
34
+ end
35
+ ```
36
+ * Non-breaking for classic applications nor modular non-nested applications.
37
+
38
+ Fixes issues introduced by #1015 (in 0.35.0), when we first introduced Sinatra support for modular applications.
39
+
40
+ The main issue we had to solve for modular support is how to handle nested applications, as only one application is actually responsible for handling the route. A naive implementation would cause the creation of nested `sinatra.request` spans, even for applications that did not handle the request. This is technically correct, as Sinatra is traversing that middleware, accruing overhead, but that does not aligned with our existing behavior of having a single `sinatra.request` span.
41
+
42
+ While trying to achieve backwards-compatibility, we had to resort to a solution that turned out brittle: `sinatra.request` spans had to start in one middleware level and finished it in another. This allowed us to only capture the `sinatra.request` for the matching route, and skip the non-matching one. This caused unexpected issues on some user setups, specially around Sinatra middleware that created spans in between the initialization and closure of `sinatra.request` spans.
43
+
44
+ This change now address these implementation issues by creating multiple `sinatra.request`, one for each traversed Sinatra application, even non-matching ones. This instrumentation is more correct, but at the cost of being a breaking change for nested modular applications.
45
+
46
+ Please see #1145 for more information, and example screenshots on how traces for affected applications will look like.
47
+
48
+ - Rack/Rails span error propagation with `rescue_from` (#1155, #1162)
49
+ - Prevent logger recursion during startup (#1158)
50
+ - Race condition on new worker classes (#1154)
51
+ - These classes represent future work, and not being used at the moment.
52
+
53
+ ### Refactored
54
+
55
+ - Run CI tests in parallel (#1156)
56
+ - Migrate minitest tests to RSpec (#1127, #1128, #1133, #1149, #1152, #1153)
57
+ - Improvements to test suite (#1134, #1148, #1163)
58
+ - Improvements to documentation (#1138)
59
+
60
+ ### Removed
61
+
62
+ - **Ruby 1.9 support ended, as it transitions from Maintenance to End-Of-Life (#1137)**
63
+ - GitLab status check when not applicable (#1160)
64
+ - Allows for PRs pass all status checks once again. Before this change, a `dd-gitlab/copy_to_s3` check would never leave the "Pending" status. This check tracks the deployment of a commit to an internal testing platform, which currently only happens on `master` branch or when manually triggered internally.
65
+
5
66
  ## [0.39.0] - 2020-08-05
6
67
 
7
68
  Release notes: https://github.com/DataDog/dd-trace-rb/releases/tag/v0.39.0
@@ -1334,7 +1395,8 @@ Release notes: https://github.com/DataDog/dd-trace-rb/releases/tag/v0.3.1
1334
1395
 
1335
1396
  Git diff: https://github.com/DataDog/dd-trace-rb/compare/v0.3.0...v0.3.1
1336
1397
 
1337
- [Unreleased]: https://github.com/DataDog/dd-trace-rb/compare/v0.39.0...master
1398
+ [Unreleased]: https://github.com/DataDog/dd-trace-rb/compare/v0.40.0...master
1399
+ [0.40.0]: https://github.com/DataDog/dd-trace-rb/compare/v0.39.0...v0.40.0
1338
1400
  [0.39.0]: https://github.com/DataDog/dd-trace-rb/compare/v0.38.0...v0.39.0
1339
1401
  [0.38.0]: https://github.com/DataDog/dd-trace-rb/compare/v0.37.0...v0.38.0
1340
1402
  [0.37.0]: https://github.com/DataDog/dd-trace-rb/compare/v0.36.0...v0.37.0
data/Rakefile CHANGED
@@ -100,6 +100,7 @@ namespace :spec do
100
100
  :mongodb,
101
101
  :mysql2,
102
102
  :presto,
103
+ :que,
103
104
  :racecar,
104
105
  :rack,
105
106
  :rake,
@@ -142,8 +143,6 @@ namespace :test do
142
143
  end
143
144
 
144
145
  [
145
- :grape,
146
- :sucker_punch
147
146
  ].each do |contrib|
148
147
  Rake::TestTask.new(contrib) do |t|
149
148
  t.libs << %w[test lib]
@@ -185,6 +184,21 @@ task :'release:docs' => :docs do
185
184
  sh "aws s3 cp --recursive doc/ s3://#{S3_BUCKET}/#{S3_DIR}/docs/"
186
185
  end
187
186
 
187
+ # Declare a command for execution.
188
+ # Jobs are parallelized if running in CI.
189
+ def declare(*args)
190
+ total_executors = ENV.key?('CIRCLE_NODE_TOTAL') ? ENV['CIRCLE_NODE_TOTAL'].to_i : nil
191
+ current_executor = ENV.key?('CIRCLE_NODE_INDEX') ? ENV['CIRCLE_NODE_INDEX'].to_i : nil
192
+
193
+ if total_executors && current_executor && total_executors > 1
194
+ @execution_count ||= 0
195
+ @execution_count += 1
196
+ sh(*args) if @execution_count % total_executors == current_executor
197
+ else
198
+ sh(*args)
199
+ end
200
+ end
201
+
188
202
  desc 'CI task; it runs all tests for current version of Ruby'
189
203
  task :ci do
190
204
  if Gem::Version.new(RUBY_VERSION) < Gem::Version.new(Datadog::VERSION::MINIMUM_RUBY_VERSION)
@@ -192,563 +206,584 @@ task :ci do
192
206
  elsif Gem::Version.new('2.0.0') <= Gem::Version.new(RUBY_VERSION) \
193
207
  && Gem::Version.new(RUBY_VERSION) < Gem::Version.new('2.1.0')
194
208
  # Main library
195
- sh 'bundle exec rake test:main'
196
- sh 'bundle exec rake spec:main'
197
- sh 'bundle exec rake spec:contrib'
209
+ declare 'bundle exec rake test:main'
210
+ declare 'bundle exec rake spec:main'
211
+ declare 'bundle exec rake spec:contrib'
198
212
  # Benchmarks
199
- sh 'bundle exec rake spec:benchmark'
213
+ declare 'bundle exec rake spec:benchmark'
200
214
 
201
215
  if RUBY_PLATFORM != 'java'
202
216
  # Contrib minitests
203
- sh 'bundle exec appraisal contrib-old rake test:monkey'
204
- sh 'bundle exec appraisal contrib-old rake test:sucker_punch'
217
+ declare 'bundle exec appraisal contrib-old rake test:monkey'
205
218
  # Contrib specs
206
- sh 'bundle exec appraisal contrib-old rake spec:active_model_serializers'
207
- sh 'bundle exec appraisal contrib-old rake spec:active_record'
208
- sh 'bundle exec appraisal contrib-old rake spec:active_support'
209
- sh 'bundle exec appraisal contrib-old rake spec:aws'
210
- sh 'bundle exec appraisal contrib-old rake spec:concurrent_ruby'
211
- sh 'bundle exec appraisal contrib-old rake spec:dalli'
212
- sh 'bundle exec appraisal contrib-old rake spec:delayed_job'
213
- sh 'bundle exec appraisal contrib-old rake spec:elasticsearch'
214
- sh 'bundle exec appraisal contrib-old rake spec:ethon'
215
- sh 'bundle exec appraisal contrib-old rake spec:excon'
216
- sh 'bundle exec appraisal contrib-old rake spec:faraday'
217
- sh 'bundle exec appraisal contrib-old rake spec:http'
218
- sh 'bundle exec appraisal contrib-old rake spec:httprb'
219
- sh 'bundle exec appraisal contrib-old rake spec:mongodb'
220
- sh 'bundle exec appraisal contrib-old rake spec:mysql2'
221
- sh 'bundle exec appraisal contrib-old rake spec:rack'
222
- sh 'bundle exec appraisal contrib-old rake spec:rake'
223
- sh 'bundle exec appraisal contrib-old rake spec:redis'
224
- sh 'bundle exec appraisal contrib-old rake spec:resque'
225
- sh 'bundle exec appraisal contrib-old rake spec:rest_client'
226
- sh 'bundle exec appraisal contrib-old rake spec:sequel'
227
- sh 'bundle exec appraisal contrib-old rake spec:sidekiq'
228
- sh 'bundle exec appraisal contrib-old rake spec:sinatra'
229
- sh 'bundle exec appraisal contrib-old rake spec:sucker_punch'
230
- sh 'bundle exec appraisal contrib-old rake spec:suite'
219
+ declare 'bundle exec appraisal contrib-old rake spec:active_model_serializers'
220
+ declare 'bundle exec appraisal contrib-old rake spec:active_record'
221
+ declare 'bundle exec appraisal contrib-old rake spec:active_support'
222
+ declare 'bundle exec appraisal contrib-old rake spec:aws'
223
+ declare 'bundle exec appraisal contrib-old rake spec:concurrent_ruby'
224
+ declare 'bundle exec appraisal contrib-old rake spec:dalli'
225
+ declare 'bundle exec appraisal contrib-old rake spec:delayed_job'
226
+ declare 'bundle exec appraisal contrib-old rake spec:elasticsearch'
227
+ declare 'bundle exec appraisal contrib-old rake spec:ethon'
228
+ declare 'bundle exec appraisal contrib-old rake spec:excon'
229
+ declare 'bundle exec appraisal contrib-old rake spec:faraday'
230
+ declare 'bundle exec appraisal contrib-old rake spec:http'
231
+ declare 'bundle exec appraisal contrib-old rake spec:httprb'
232
+ declare 'bundle exec appraisal contrib-old rake spec:mongodb'
233
+ declare 'bundle exec appraisal contrib-old rake spec:mysql2'
234
+ declare 'bundle exec appraisal contrib-old rake spec:rack'
235
+ declare 'bundle exec appraisal contrib-old rake spec:rake'
236
+ declare 'bundle exec appraisal contrib-old rake spec:redis'
237
+ declare 'bundle exec appraisal contrib-old rake spec:resque'
238
+ declare 'bundle exec appraisal contrib-old rake spec:rest_client'
239
+ declare 'bundle exec appraisal contrib-old rake spec:sequel'
240
+ declare 'bundle exec appraisal contrib-old rake spec:sidekiq'
241
+ declare 'bundle exec appraisal contrib-old rake spec:sinatra'
242
+ declare 'bundle exec appraisal contrib-old rake spec:sucker_punch'
243
+ declare 'bundle exec appraisal contrib-old rake spec:suite'
231
244
  # Rails minitests
232
- sh 'bundle exec appraisal rails30-postgres rake test:rails'
233
- sh 'bundle exec appraisal rails30-postgres rake spec:railsdisableenv'
234
- sh 'bundle exec appraisal rails32-mysql2 rake test:rails'
235
- sh 'bundle exec appraisal rails32-postgres rake test:rails'
236
- sh 'bundle exec appraisal rails32-postgres-redis rake spec:railsredis'
237
- sh 'bundle exec appraisal rails32-postgres rake spec:railsdisableenv'
245
+ declare 'bundle exec appraisal rails30-postgres rake test:rails'
246
+ declare 'bundle exec appraisal rails30-postgres rake spec:railsdisableenv'
247
+ declare 'bundle exec appraisal rails32-mysql2 rake test:rails'
248
+ declare 'bundle exec appraisal rails32-postgres rake test:rails'
249
+ declare 'bundle exec appraisal rails32-postgres-redis rake spec:railsredis'
250
+ declare 'bundle exec appraisal rails32-postgres rake spec:railsdisableenv'
238
251
  # Rails specs
239
- sh 'bundle exec appraisal rails30-postgres rake spec:rails'
240
- sh 'bundle exec appraisal rails32-mysql2 rake spec:rails'
241
- sh 'bundle exec appraisal rails32-postgres rake spec:rails'
252
+ declare 'bundle exec appraisal rails30-postgres rake spec:rails'
253
+ declare 'bundle exec appraisal rails32-mysql2 rake spec:rails'
254
+ declare 'bundle exec appraisal rails32-postgres rake spec:rails'
242
255
  # Rails suite specs
243
- sh 'bundle exec appraisal rails32-postgres rake spec:action_pack'
244
- sh 'bundle exec appraisal rails32-postgres rake spec:action_view'
245
- sh 'bundle exec appraisal rails32-mysql2 rake spec:active_record'
246
- sh 'bundle exec appraisal rails32-postgres rake spec:active_support'
256
+ declare 'bundle exec appraisal rails32-postgres rake spec:action_pack'
257
+ declare 'bundle exec appraisal rails32-postgres rake spec:action_view'
258
+ declare 'bundle exec appraisal rails32-mysql2 rake spec:active_record'
259
+ declare 'bundle exec appraisal rails32-postgres rake spec:active_support'
247
260
  end
248
261
  elsif Gem::Version.new('2.1.0') <= Gem::Version.new(RUBY_VERSION) \
249
262
  && Gem::Version.new(RUBY_VERSION) < Gem::Version.new('2.2.0')
250
263
  # Main library
251
- sh 'bundle exec rake test:main'
252
- sh 'bundle exec rake spec:main'
253
- sh 'bundle exec rake spec:contrib'
254
- sh 'bundle exec rake spec:opentracer'
264
+ declare 'bundle exec rake test:main'
265
+ declare 'bundle exec rake spec:main'
266
+ declare 'bundle exec rake spec:contrib'
267
+ declare 'bundle exec rake spec:opentracer'
255
268
  # Benchmarks
256
- sh 'bundle exec rake spec:benchmark'
269
+ declare 'bundle exec rake spec:benchmark'
257
270
 
258
271
  if RUBY_PLATFORM != 'java'
259
272
  # Contrib minitests
260
- sh 'bundle exec appraisal contrib-old rake test:monkey'
261
- sh 'bundle exec appraisal contrib-old rake test:sucker_punch'
273
+ declare 'bundle exec appraisal contrib-old rake test:monkey'
262
274
  # Contrib specs
263
- sh 'bundle exec appraisal contrib-old rake spec:active_model_serializers'
264
- sh 'bundle exec appraisal contrib-old rake spec:active_record'
265
- sh 'bundle exec appraisal contrib-old rake spec:active_support'
266
- sh 'bundle exec appraisal contrib-old rake spec:aws'
267
- sh 'bundle exec appraisal contrib-old rake spec:concurrent_ruby'
268
- sh 'bundle exec appraisal contrib-old rake spec:dalli'
269
- sh 'bundle exec appraisal contrib-old rake spec:delayed_job'
270
- sh 'bundle exec appraisal contrib-old rake spec:elasticsearch'
271
- sh 'bundle exec appraisal contrib-old rake spec:ethon'
272
- sh 'bundle exec appraisal contrib-old rake spec:excon'
273
- sh 'bundle exec appraisal contrib-old rake spec:faraday'
274
- sh 'bundle exec appraisal contrib-old rake spec:http'
275
- sh 'bundle exec appraisal contrib-old rake spec:httprb'
276
- sh 'bundle exec appraisal contrib-old rake spec:mongodb'
277
- sh 'bundle exec appraisal contrib-old rake spec:mysql2'
278
- sh 'bundle exec appraisal contrib-old rake spec:presto'
279
- sh 'bundle exec appraisal contrib-old rake spec:rack'
280
- sh 'bundle exec appraisal contrib-old rake spec:rake'
281
- sh 'bundle exec appraisal contrib-old rake spec:redis'
282
- sh 'bundle exec appraisal contrib-old rake spec:resque'
283
- sh 'bundle exec appraisal contrib-old rake spec:rest_client'
284
- sh 'bundle exec appraisal contrib-old rake spec:sequel'
285
- sh 'bundle exec appraisal contrib-old rake spec:sidekiq'
286
- sh 'bundle exec appraisal contrib-old rake spec:sinatra'
287
- sh 'bundle exec appraisal contrib-old rake spec:sucker_punch'
288
- sh 'bundle exec appraisal contrib-old rake spec:suite'
275
+ declare 'bundle exec appraisal contrib-old rake spec:active_model_serializers'
276
+ declare 'bundle exec appraisal contrib-old rake spec:active_record'
277
+ declare 'bundle exec appraisal contrib-old rake spec:active_support'
278
+ declare 'bundle exec appraisal contrib-old rake spec:aws'
279
+ declare 'bundle exec appraisal contrib-old rake spec:concurrent_ruby'
280
+ declare 'bundle exec appraisal contrib-old rake spec:dalli'
281
+ declare 'bundle exec appraisal contrib-old rake spec:delayed_job'
282
+ declare 'bundle exec appraisal contrib-old rake spec:elasticsearch'
283
+ declare 'bundle exec appraisal contrib-old rake spec:ethon'
284
+ declare 'bundle exec appraisal contrib-old rake spec:excon'
285
+ declare 'bundle exec appraisal contrib-old rake spec:faraday'
286
+ declare 'bundle exec appraisal contrib-old rake spec:http'
287
+ declare 'bundle exec appraisal contrib-old rake spec:httprb'
288
+ declare 'bundle exec appraisal contrib-old rake spec:mongodb'
289
+ declare 'bundle exec appraisal contrib-old rake spec:mysql2'
290
+ declare 'bundle exec appraisal contrib-old rake spec:presto'
291
+ declare 'bundle exec appraisal contrib-old rake spec:rack'
292
+ declare 'bundle exec appraisal contrib-old rake spec:rake'
293
+ declare 'bundle exec appraisal contrib-old rake spec:redis'
294
+ declare 'bundle exec appraisal contrib-old rake spec:resque'
295
+ declare 'bundle exec appraisal contrib-old rake spec:rest_client'
296
+ declare 'bundle exec appraisal contrib-old rake spec:sequel'
297
+ declare 'bundle exec appraisal contrib-old rake spec:sidekiq'
298
+ declare 'bundle exec appraisal contrib-old rake spec:sinatra'
299
+ declare 'bundle exec appraisal contrib-old rake spec:sucker_punch'
300
+ declare 'bundle exec appraisal contrib-old rake spec:suite'
289
301
  # Rails minitests
290
- sh 'bundle exec appraisal rails30-postgres rake test:rails'
291
- sh 'bundle exec appraisal rails30-postgres rake spec:railsdisableenv'
292
- sh 'bundle exec appraisal rails32-mysql2 rake test:rails'
293
- sh 'bundle exec appraisal rails32-postgres rake test:rails'
294
- sh 'bundle exec appraisal rails32-postgres-redis rake spec:railsredis'
295
- sh 'bundle exec appraisal rails32-postgres rake spec:railsdisableenv'
296
- sh 'bundle exec appraisal rails4-mysql2 rake test:rails'
297
- sh 'bundle exec appraisal rails4-postgres rake test:rails'
298
- sh 'bundle exec appraisal rails4-postgres-redis rake spec:railsredis'
299
- sh 'bundle exec appraisal rails4-postgres rake spec:railsdisableenv'
302
+ declare 'bundle exec appraisal rails30-postgres rake test:rails'
303
+ declare 'bundle exec appraisal rails30-postgres rake spec:railsdisableenv'
304
+ declare 'bundle exec appraisal rails32-mysql2 rake test:rails'
305
+ declare 'bundle exec appraisal rails32-postgres rake test:rails'
306
+ declare 'bundle exec appraisal rails32-postgres-redis rake spec:railsredis'
307
+ declare 'bundle exec appraisal rails32-postgres rake spec:railsdisableenv'
308
+ declare 'bundle exec appraisal rails4-mysql2 rake test:rails'
309
+ declare 'bundle exec appraisal rails4-postgres rake test:rails'
310
+ declare 'bundle exec appraisal rails4-postgres-redis rake spec:railsredis'
311
+ declare 'bundle exec appraisal rails4-postgres rake spec:railsdisableenv'
300
312
  # Rails specs
301
- sh 'bundle exec appraisal rails30-postgres rake spec:rails'
302
- sh 'bundle exec appraisal rails32-mysql2 rake spec:rails'
303
- sh 'bundle exec appraisal rails32-postgres rake spec:rails'
304
- sh 'bundle exec appraisal rails4-mysql2 rake spec:rails'
305
- sh 'bundle exec appraisal rails4-postgres rake spec:rails'
313
+ declare 'bundle exec appraisal rails30-postgres rake spec:rails'
314
+ declare 'bundle exec appraisal rails32-mysql2 rake spec:rails'
315
+ declare 'bundle exec appraisal rails32-postgres rake spec:rails'
316
+ declare 'bundle exec appraisal rails4-mysql2 rake spec:rails'
317
+ declare 'bundle exec appraisal rails4-postgres rake spec:rails'
306
318
  # Rails suite specs
307
- sh 'bundle exec appraisal rails32-postgres rake spec:action_pack'
308
- sh 'bundle exec appraisal rails32-postgres rake spec:action_view'
309
- sh 'bundle exec appraisal rails32-mysql2 rake spec:active_record'
310
- sh 'bundle exec appraisal rails32-postgres rake spec:active_support'
319
+ declare 'bundle exec appraisal rails32-postgres rake spec:action_pack'
320
+ declare 'bundle exec appraisal rails32-postgres rake spec:action_view'
321
+ declare 'bundle exec appraisal rails32-mysql2 rake spec:active_record'
322
+ declare 'bundle exec appraisal rails32-postgres rake spec:active_support'
311
323
  end
312
324
  elsif Gem::Version.new('2.2.0') <= Gem::Version.new(RUBY_VERSION)\
313
325
  && Gem::Version.new(RUBY_VERSION) < Gem::Version.new('2.3.0')
314
326
  # Main library
315
- sh 'bundle exec rake test:main'
316
- sh 'bundle exec rake spec:main'
317
- sh 'bundle exec rake spec:contrib'
318
- sh 'bundle exec rake spec:opentracer'
327
+ declare 'bundle exec rake test:main'
328
+ declare 'bundle exec rake spec:main'
329
+ declare 'bundle exec rake spec:contrib'
330
+ declare 'bundle exec rake spec:opentracer'
319
331
  # Benchmarks
320
- sh 'bundle exec rake spec:benchmark'
332
+ declare 'bundle exec rake spec:benchmark'
321
333
 
322
334
  if RUBY_PLATFORM != 'java'
323
335
  # Contrib minitests
324
- sh 'bundle exec appraisal contrib rake test:grape'
325
- sh 'bundle exec appraisal contrib rake test:sucker_punch'
326
336
  # Contrib specs
327
- sh 'bundle exec appraisal contrib rake spec:action_pack'
328
- sh 'bundle exec appraisal contrib rake spec:action_view'
329
- sh 'bundle exec appraisal contrib rake spec:active_model_serializers'
330
- sh 'bundle exec appraisal contrib rake spec:active_record'
331
- sh 'bundle exec appraisal contrib rake spec:active_support'
332
- sh 'bundle exec appraisal contrib rake spec:aws'
333
- sh 'bundle exec appraisal contrib rake spec:concurrent_ruby'
334
- sh 'bundle exec appraisal contrib rake spec:dalli'
335
- sh 'bundle exec appraisal contrib rake spec:delayed_job'
336
- sh 'bundle exec appraisal contrib rake spec:elasticsearch'
337
- sh 'bundle exec appraisal contrib rake spec:ethon'
338
- sh 'bundle exec appraisal contrib rake spec:excon'
339
- sh 'bundle exec appraisal contrib rake spec:faraday'
340
- sh 'bundle exec appraisal contrib rake spec:grape'
341
- sh 'bundle exec appraisal contrib rake spec:graphql'
342
- sh 'bundle exec appraisal contrib rake spec:grpc'
343
- sh 'bundle exec appraisal contrib rake spec:http'
344
- sh 'bundle exec appraisal contrib rake spec:httprb'
345
- sh 'bundle exec appraisal contrib rake spec:mongodb'
346
- sh 'bundle exec appraisal contrib rake spec:mysql2'
347
- sh 'bundle exec appraisal contrib rake spec:presto'
348
- sh 'bundle exec appraisal contrib rake spec:racecar'
349
- sh 'bundle exec appraisal contrib rake spec:rack'
350
- sh 'bundle exec appraisal contrib rake spec:rake'
351
- sh 'bundle exec appraisal contrib rake spec:redis'
352
- sh 'bundle exec appraisal contrib rake spec:resque'
353
- sh 'bundle exec appraisal contrib rake spec:rest_client'
354
- sh 'bundle exec appraisal contrib rake spec:sequel'
355
- sh 'bundle exec appraisal contrib rake spec:shoryuken'
356
- sh 'bundle exec appraisal contrib rake spec:sidekiq'
357
- sh 'bundle exec appraisal contrib rake spec:sinatra'
358
- sh 'bundle exec appraisal contrib rake spec:sneakers'
359
- sh 'bundle exec appraisal contrib rake spec:sucker_punch'
360
- sh 'bundle exec appraisal contrib rake spec:suite'
337
+ declare 'bundle exec appraisal contrib rake spec:action_pack'
338
+ declare 'bundle exec appraisal contrib rake spec:action_view'
339
+ declare 'bundle exec appraisal contrib rake spec:active_model_serializers'
340
+ declare 'bundle exec appraisal contrib rake spec:active_record'
341
+ declare 'bundle exec appraisal contrib rake spec:active_support'
342
+ declare 'bundle exec appraisal contrib rake spec:aws'
343
+ declare 'bundle exec appraisal contrib rake spec:concurrent_ruby'
344
+ declare 'bundle exec appraisal contrib rake spec:dalli'
345
+ declare 'bundle exec appraisal contrib rake spec:delayed_job'
346
+ declare 'bundle exec appraisal contrib rake spec:elasticsearch'
347
+ declare 'bundle exec appraisal contrib rake spec:ethon'
348
+ declare 'bundle exec appraisal contrib rake spec:excon'
349
+ declare 'bundle exec appraisal contrib rake spec:faraday'
350
+ declare 'bundle exec appraisal contrib rake spec:grape'
351
+ declare 'bundle exec appraisal contrib rake spec:graphql'
352
+ declare 'bundle exec appraisal contrib rake spec:grpc'
353
+ declare 'bundle exec appraisal contrib rake spec:http'
354
+ declare 'bundle exec appraisal contrib rake spec:httprb'
355
+ declare 'bundle exec appraisal contrib rake spec:mongodb'
356
+ declare 'bundle exec appraisal contrib rake spec:mysql2'
357
+ declare 'bundle exec appraisal contrib rake spec:presto'
358
+ declare 'bundle exec appraisal contrib rake spec:que'
359
+ declare 'bundle exec appraisal contrib rake spec:racecar'
360
+ declare 'bundle exec appraisal contrib rake spec:rack'
361
+ declare 'bundle exec appraisal contrib rake spec:rake'
362
+ declare 'bundle exec appraisal contrib rake spec:redis'
363
+ declare 'bundle exec appraisal contrib rake spec:resque'
364
+ declare 'bundle exec appraisal contrib rake spec:rest_client'
365
+ declare 'bundle exec appraisal contrib rake spec:sequel'
366
+ declare 'bundle exec appraisal contrib rake spec:shoryuken'
367
+ declare 'bundle exec appraisal contrib rake spec:sidekiq'
368
+ declare 'bundle exec appraisal contrib rake spec:sinatra'
369
+ declare 'bundle exec appraisal contrib rake spec:sneakers'
370
+ declare 'bundle exec appraisal contrib rake spec:sucker_punch'
371
+ declare 'bundle exec appraisal contrib rake spec:suite'
361
372
  # Rails minitests
362
- sh 'bundle exec appraisal rails30-postgres rake test:rails'
363
- sh 'bundle exec appraisal rails30-postgres rake spec:railsdisableenv'
364
- sh 'bundle exec appraisal rails32-mysql2 rake test:rails'
365
- sh 'bundle exec appraisal rails32-postgres rake test:rails'
366
- sh 'bundle exec appraisal rails32-postgres-redis rake spec:railsredis'
367
- sh 'bundle exec appraisal rails32-postgres rake spec:railsdisableenv'
368
- sh 'bundle exec appraisal rails4-mysql2 rake test:rails'
369
- sh 'bundle exec appraisal rails4-postgres rake test:rails'
370
- sh 'bundle exec appraisal rails4-postgres-redis rake spec:railsredis'
371
- sh 'bundle exec appraisal rails4-postgres rake spec:railsdisableenv'
372
- sh 'bundle exec appraisal rails4-postgres-sidekiq rake spec:railsactivejob'
373
- sh 'bundle exec appraisal rails5-mysql2 rake test:rails'
374
- sh 'bundle exec appraisal rails5-postgres rake test:rails'
375
- sh 'bundle exec appraisal rails5-postgres-redis rake spec:railsredis'
376
- sh 'bundle exec appraisal rails5-postgres-redis-activesupport rake spec:railsredis'
377
- sh 'bundle exec appraisal rails5-postgres-sidekiq rake spec:railsactivejob'
378
- sh 'bundle exec appraisal rails5-postgres rake spec:railsdisableenv'
373
+ declare 'bundle exec appraisal rails30-postgres rake test:rails'
374
+ declare 'bundle exec appraisal rails30-postgres rake spec:railsdisableenv'
375
+ declare 'bundle exec appraisal rails32-mysql2 rake test:rails'
376
+ declare 'bundle exec appraisal rails32-postgres rake test:rails'
377
+ declare 'bundle exec appraisal rails32-postgres-redis rake spec:railsredis'
378
+ declare 'bundle exec appraisal rails32-postgres rake spec:railsdisableenv'
379
+ declare 'bundle exec appraisal rails4-mysql2 rake test:rails'
380
+ declare 'bundle exec appraisal rails4-postgres rake test:rails'
381
+ declare 'bundle exec appraisal rails4-postgres-redis rake spec:railsredis'
382
+ declare 'bundle exec appraisal rails4-postgres rake spec:railsdisableenv'
383
+ declare 'bundle exec appraisal rails4-postgres-sidekiq rake spec:railsactivejob'
384
+ declare 'bundle exec appraisal rails5-mysql2 rake test:rails'
385
+ declare 'bundle exec appraisal rails5-postgres rake test:rails'
386
+ declare 'bundle exec appraisal rails5-postgres-redis rake spec:railsredis'
387
+ declare 'bundle exec appraisal rails5-postgres-redis-activesupport rake spec:railsredis'
388
+ declare 'bundle exec appraisal rails5-postgres-sidekiq rake spec:railsactivejob'
389
+ declare 'bundle exec appraisal rails5-postgres rake spec:railsdisableenv'
379
390
  # Rails specs
380
- sh 'bundle exec appraisal rails30-postgres rake spec:rails'
381
- sh 'bundle exec appraisal rails32-mysql2 rake spec:rails'
382
- sh 'bundle exec appraisal rails32-postgres rake spec:rails'
383
- sh 'bundle exec appraisal rails4-mysql2 rake spec:rails'
384
- sh 'bundle exec appraisal rails4-postgres rake spec:rails'
385
- sh 'bundle exec appraisal rails5-mysql2 rake spec:rails'
386
- sh 'bundle exec appraisal rails5-postgres rake spec:rails'
391
+ declare 'bundle exec appraisal rails30-postgres rake spec:rails'
392
+ declare 'bundle exec appraisal rails32-mysql2 rake spec:rails'
393
+ declare 'bundle exec appraisal rails32-postgres rake spec:rails'
394
+ declare 'bundle exec appraisal rails4-mysql2 rake spec:rails'
395
+ declare 'bundle exec appraisal rails4-postgres rake spec:rails'
396
+ declare 'bundle exec appraisal rails5-mysql2 rake spec:rails'
397
+ declare 'bundle exec appraisal rails5-postgres rake spec:rails'
387
398
  end
388
399
  elsif Gem::Version.new('2.3.0') <= Gem::Version.new(RUBY_VERSION) \
389
400
  && Gem::Version.new(RUBY_VERSION) < Gem::Version.new('2.4.0')
390
401
  # Main library
391
- sh 'bundle exec rake test:main'
392
- sh 'bundle exec rake spec:main'
393
- sh 'bundle exec rake spec:contrib'
394
- sh 'bundle exec rake spec:opentracer'
402
+ declare 'bundle exec rake test:main'
403
+ declare 'bundle exec rake spec:main'
404
+ declare 'bundle exec rake spec:contrib'
405
+ declare 'bundle exec rake spec:opentracer'
395
406
  # Benchmarks
396
- sh 'bundle exec rake spec:benchmark'
407
+ declare 'bundle exec rake spec:benchmark'
397
408
 
398
409
  if RUBY_PLATFORM != 'java'
399
410
  # Contrib minitests
400
- sh 'bundle exec appraisal contrib rake test:grape'
401
- sh 'bundle exec appraisal contrib rake test:sucker_punch'
402
411
  # Contrib specs
403
- sh 'bundle exec appraisal contrib rake spec:action_pack'
404
- sh 'bundle exec appraisal contrib rake spec:action_view'
405
- sh 'bundle exec appraisal contrib rake spec:active_model_serializers'
406
- sh 'bundle exec appraisal contrib rake spec:active_record'
407
- sh 'bundle exec appraisal contrib rake spec:active_support'
408
- sh 'bundle exec appraisal contrib rake spec:aws'
409
- sh 'bundle exec appraisal contrib rake spec:concurrent_ruby'
410
- sh 'bundle exec appraisal contrib rake spec:dalli'
411
- sh 'bundle exec appraisal contrib rake spec:delayed_job'
412
- sh 'bundle exec appraisal contrib rake spec:elasticsearch'
413
- sh 'bundle exec appraisal contrib rake spec:ethon'
414
- sh 'bundle exec appraisal contrib rake spec:excon'
415
- sh 'bundle exec appraisal contrib rake spec:faraday'
416
- sh 'bundle exec appraisal contrib rake spec:grape'
417
- sh 'bundle exec appraisal contrib rake spec:graphql'
418
- sh 'bundle exec appraisal contrib rake spec:grpc'
419
- sh 'bundle exec appraisal contrib rake spec:http'
420
- sh 'bundle exec appraisal contrib rake spec:httprb'
421
- sh 'bundle exec appraisal contrib rake spec:mongodb'
422
- sh 'bundle exec appraisal contrib rake spec:mysql2'
423
- sh 'bundle exec appraisal contrib rake spec:presto'
424
- sh 'bundle exec appraisal contrib rake spec:racecar'
425
- sh 'bundle exec appraisal contrib rake spec:rack'
426
- sh 'bundle exec appraisal contrib rake spec:rake'
427
- sh 'bundle exec appraisal contrib rake spec:redis'
428
- sh 'bundle exec appraisal contrib rake spec:resque'
429
- sh 'bundle exec appraisal contrib rake spec:rest_client'
430
- sh 'bundle exec appraisal contrib rake spec:sequel'
431
- sh 'bundle exec appraisal contrib rake spec:shoryuken'
432
- sh 'bundle exec appraisal contrib rake spec:sidekiq'
433
- sh 'bundle exec appraisal contrib rake spec:sinatra'
434
- sh 'bundle exec appraisal contrib rake spec:sneakers'
435
- sh 'bundle exec appraisal contrib rake spec:sucker_punch'
436
- sh 'bundle exec appraisal contrib rake spec:suite'
412
+ declare 'bundle exec appraisal contrib rake spec:action_pack'
413
+ declare 'bundle exec appraisal contrib rake spec:action_view'
414
+ declare 'bundle exec appraisal contrib rake spec:active_model_serializers'
415
+ declare 'bundle exec appraisal contrib rake spec:active_record'
416
+ declare 'bundle exec appraisal contrib rake spec:active_support'
417
+ declare 'bundle exec appraisal contrib rake spec:aws'
418
+ declare 'bundle exec appraisal contrib rake spec:concurrent_ruby'
419
+ declare 'bundle exec appraisal contrib rake spec:dalli'
420
+ declare 'bundle exec appraisal contrib rake spec:delayed_job'
421
+ declare 'bundle exec appraisal contrib rake spec:elasticsearch'
422
+ declare 'bundle exec appraisal contrib rake spec:ethon'
423
+ declare 'bundle exec appraisal contrib rake spec:excon'
424
+ declare 'bundle exec appraisal contrib rake spec:faraday'
425
+ declare 'bundle exec appraisal contrib rake spec:grape'
426
+ declare 'bundle exec appraisal contrib rake spec:graphql'
427
+ declare 'bundle exec appraisal contrib rake spec:grpc'
428
+ declare 'bundle exec appraisal contrib rake spec:http'
429
+ declare 'bundle exec appraisal contrib rake spec:httprb'
430
+ declare 'bundle exec appraisal contrib rake spec:mongodb'
431
+ declare 'bundle exec appraisal contrib rake spec:mysql2'
432
+ declare 'bundle exec appraisal contrib rake spec:presto'
433
+ declare 'bundle exec appraisal contrib rake spec:que'
434
+ declare 'bundle exec appraisal contrib rake spec:racecar'
435
+ declare 'bundle exec appraisal contrib rake spec:rack'
436
+ declare 'bundle exec appraisal contrib rake spec:rake'
437
+ declare 'bundle exec appraisal contrib rake spec:redis'
438
+ declare 'bundle exec appraisal contrib rake spec:resque'
439
+ declare 'bundle exec appraisal contrib rake spec:rest_client'
440
+ declare 'bundle exec appraisal contrib rake spec:sequel'
441
+ declare 'bundle exec appraisal contrib rake spec:shoryuken'
442
+ declare 'bundle exec appraisal contrib rake spec:sidekiq'
443
+ declare 'bundle exec appraisal contrib rake spec:sinatra'
444
+ declare 'bundle exec appraisal contrib rake spec:sneakers'
445
+ declare 'bundle exec appraisal contrib rake spec:sucker_punch'
446
+ declare 'bundle exec appraisal contrib rake spec:suite'
437
447
  # Contrib specs with old gem versions
438
- sh 'bundle exec appraisal contrib-old rake spec:faraday'
448
+ declare 'bundle exec appraisal contrib-old rake spec:faraday'
439
449
  # Rails minitests
440
- sh 'bundle exec appraisal rails30-postgres rake test:rails'
441
- sh 'bundle exec appraisal rails30-postgres rake spec:railsdisableenv'
442
- sh 'bundle exec appraisal rails32-mysql2 rake test:rails'
443
- sh 'bundle exec appraisal rails32-postgres rake test:rails'
444
- sh 'bundle exec appraisal rails32-postgres-redis rake spec:railsredis'
445
- sh 'bundle exec appraisal rails32-postgres rake spec:railsdisableenv'
446
- sh 'bundle exec appraisal rails4-mysql2 rake test:rails'
447
- sh 'bundle exec appraisal rails4-postgres rake test:rails'
448
- sh 'bundle exec appraisal rails4-postgres-redis rake spec:railsredis'
449
- sh 'bundle exec appraisal rails4-postgres rake spec:railsdisableenv'
450
- sh 'bundle exec appraisal rails4-postgres-sidekiq rake spec:railsactivejob'
451
- sh 'bundle exec appraisal rails5-mysql2 rake test:rails'
452
- sh 'bundle exec appraisal rails5-postgres rake test:rails'
453
- sh 'bundle exec appraisal rails5-postgres-redis rake spec:railsredis'
454
- sh 'bundle exec appraisal rails5-postgres-redis-activesupport rake spec:railsredis'
455
- sh 'bundle exec appraisal rails5-postgres-sidekiq rake spec:railsactivejob'
456
- sh 'bundle exec appraisal rails5-postgres rake spec:railsdisableenv'
450
+ declare 'bundle exec appraisal rails30-postgres rake test:rails'
451
+ declare 'bundle exec appraisal rails30-postgres rake spec:railsdisableenv'
452
+ declare 'bundle exec appraisal rails32-mysql2 rake test:rails'
453
+ declare 'bundle exec appraisal rails32-postgres rake test:rails'
454
+ declare 'bundle exec appraisal rails32-postgres-redis rake spec:railsredis'
455
+ declare 'bundle exec appraisal rails32-postgres rake spec:railsdisableenv'
456
+ declare 'bundle exec appraisal rails4-mysql2 rake test:rails'
457
+ declare 'bundle exec appraisal rails4-postgres rake test:rails'
458
+ declare 'bundle exec appraisal rails4-postgres-redis rake spec:railsredis'
459
+ declare 'bundle exec appraisal rails4-postgres rake spec:railsdisableenv'
460
+ declare 'bundle exec appraisal rails4-postgres-sidekiq rake spec:railsactivejob'
461
+ declare 'bundle exec appraisal rails5-mysql2 rake test:rails'
462
+ declare 'bundle exec appraisal rails5-postgres rake test:rails'
463
+ declare 'bundle exec appraisal rails5-postgres-redis rake spec:railsredis'
464
+ declare 'bundle exec appraisal rails5-postgres-redis-activesupport rake spec:railsredis'
465
+ declare 'bundle exec appraisal rails5-postgres-sidekiq rake spec:railsactivejob'
466
+ declare 'bundle exec appraisal rails5-postgres rake spec:railsdisableenv'
457
467
  # Rails specs
458
- sh 'bundle exec appraisal rails30-postgres rake spec:rails'
459
- sh 'bundle exec appraisal rails32-mysql2 rake spec:rails'
460
- sh 'bundle exec appraisal rails32-postgres rake spec:rails'
461
- sh 'bundle exec appraisal rails4-mysql2 rake spec:rails'
462
- sh 'bundle exec appraisal rails4-postgres rake spec:rails'
463
- sh 'bundle exec appraisal rails5-mysql2 rake spec:rails'
464
- sh 'bundle exec appraisal rails5-postgres rake spec:rails'
468
+ declare 'bundle exec appraisal rails30-postgres rake spec:rails'
469
+ declare 'bundle exec appraisal rails32-mysql2 rake spec:rails'
470
+ declare 'bundle exec appraisal rails32-postgres rake spec:rails'
471
+ declare 'bundle exec appraisal rails4-mysql2 rake spec:rails'
472
+ declare 'bundle exec appraisal rails4-postgres rake spec:rails'
473
+ declare 'bundle exec appraisal rails5-mysql2 rake spec:rails'
474
+ declare 'bundle exec appraisal rails5-postgres rake spec:rails'
465
475
  end
466
476
  elsif Gem::Version.new('2.4.0') <= Gem::Version.new(RUBY_VERSION) \
467
477
  && Gem::Version.new(RUBY_VERSION) < Gem::Version.new('2.5.0')
468
478
  # Main library
469
- sh 'bundle exec rake test:main'
470
- sh 'bundle exec rake spec:main'
471
- sh 'bundle exec rake spec:contrib'
472
- sh 'bundle exec rake spec:opentracer'
473
- sh 'bundle exec rake spec:opentelemetry'
479
+ declare 'bundle exec rake test:main'
480
+ declare 'bundle exec rake spec:main'
481
+ declare 'bundle exec rake spec:contrib'
482
+ declare 'bundle exec rake spec:opentracer'
483
+ declare 'bundle exec rake spec:opentelemetry'
474
484
  # Benchmarks
475
- sh 'bundle exec rake spec:benchmark'
485
+ declare 'bundle exec rake spec:benchmark'
476
486
 
477
487
  if RUBY_PLATFORM != 'java'
478
488
  # Benchmarks
479
- sh 'bundle exec rake benchmark'
489
+ declare 'bundle exec rake benchmark'
480
490
  # Contrib minitests
481
- sh 'bundle exec appraisal contrib rake test:grape'
482
- sh 'bundle exec appraisal contrib rake test:sucker_punch'
483
491
  # Contrib specs
484
- sh 'bundle exec appraisal contrib rake spec:action_pack'
485
- sh 'bundle exec appraisal contrib rake spec:action_view'
486
- sh 'bundle exec appraisal contrib rake spec:active_model_serializers'
487
- sh 'bundle exec appraisal contrib rake spec:active_record'
488
- sh 'bundle exec appraisal contrib rake spec:active_support'
489
- sh 'bundle exec appraisal contrib rake spec:aws'
490
- sh 'bundle exec appraisal contrib rake spec:concurrent_ruby'
491
- sh 'bundle exec appraisal contrib rake spec:dalli'
492
- sh 'bundle exec appraisal contrib rake spec:delayed_job'
493
- sh 'bundle exec appraisal contrib rake spec:elasticsearch'
494
- sh 'bundle exec appraisal contrib rake spec:ethon'
495
- sh 'bundle exec appraisal contrib rake spec:excon'
496
- sh 'bundle exec appraisal contrib rake spec:faraday'
497
- sh 'bundle exec appraisal contrib rake spec:grape'
498
- sh 'bundle exec appraisal contrib rake spec:graphql'
499
- sh 'bundle exec appraisal contrib rake spec:grpc'
500
- sh 'bundle exec appraisal contrib rake spec:http'
501
- sh 'bundle exec appraisal contrib rake spec:httprb'
502
- sh 'bundle exec appraisal contrib rake spec:mongodb'
503
- sh 'bundle exec appraisal contrib rake spec:mysql2'
504
- sh 'bundle exec appraisal contrib rake spec:presto'
505
- sh 'bundle exec appraisal contrib rake spec:racecar'
506
- sh 'bundle exec appraisal contrib rake spec:rack'
507
- sh 'bundle exec appraisal contrib rake spec:rake'
508
- sh 'bundle exec appraisal contrib rake spec:redis'
509
- sh 'bundle exec appraisal contrib rake spec:resque'
510
- sh 'bundle exec appraisal contrib rake spec:rest_client'
511
- sh 'bundle exec appraisal contrib rake spec:sequel'
512
- sh 'bundle exec appraisal contrib rake spec:shoryuken'
513
- sh 'bundle exec appraisal contrib rake spec:sidekiq'
514
- sh 'bundle exec appraisal contrib rake spec:sinatra'
515
- sh 'bundle exec appraisal contrib rake spec:sneakers'
516
- sh 'bundle exec appraisal contrib rake spec:sucker_punch'
517
- sh 'bundle exec appraisal contrib rake spec:suite'
492
+ declare 'bundle exec appraisal contrib rake spec:action_pack'
493
+ declare 'bundle exec appraisal contrib rake spec:action_view'
494
+ declare 'bundle exec appraisal contrib rake spec:active_model_serializers'
495
+ declare 'bundle exec appraisal contrib rake spec:active_record'
496
+ declare 'bundle exec appraisal contrib rake spec:active_support'
497
+ declare 'bundle exec appraisal contrib rake spec:aws'
498
+ declare 'bundle exec appraisal contrib rake spec:concurrent_ruby'
499
+ declare 'bundle exec appraisal contrib rake spec:dalli'
500
+ declare 'bundle exec appraisal contrib rake spec:delayed_job'
501
+ declare 'bundle exec appraisal contrib rake spec:elasticsearch'
502
+ declare 'bundle exec appraisal contrib rake spec:ethon'
503
+ declare 'bundle exec appraisal contrib rake spec:excon'
504
+ declare 'bundle exec appraisal contrib rake spec:faraday'
505
+ declare 'bundle exec appraisal contrib rake spec:grape'
506
+ declare 'bundle exec appraisal contrib rake spec:graphql'
507
+ declare 'bundle exec appraisal contrib rake spec:grpc'
508
+ declare 'bundle exec appraisal contrib rake spec:http'
509
+ declare 'bundle exec appraisal contrib rake spec:httprb'
510
+ declare 'bundle exec appraisal contrib rake spec:mongodb'
511
+ declare 'bundle exec appraisal contrib rake spec:mysql2'
512
+ declare 'bundle exec appraisal contrib rake spec:presto'
513
+ declare 'bundle exec appraisal contrib rake spec:que'
514
+ declare 'bundle exec appraisal contrib rake spec:racecar'
515
+ declare 'bundle exec appraisal contrib rake spec:rack'
516
+ declare 'bundle exec appraisal contrib rake spec:rake'
517
+ declare 'bundle exec appraisal contrib rake spec:redis'
518
+ declare 'bundle exec appraisal contrib rake spec:resque'
519
+ declare 'bundle exec appraisal contrib rake spec:rest_client'
520
+ declare 'bundle exec appraisal contrib rake spec:sequel'
521
+ declare 'bundle exec appraisal contrib rake spec:shoryuken'
522
+ declare 'bundle exec appraisal contrib rake spec:sidekiq'
523
+ declare 'bundle exec appraisal contrib rake spec:sinatra'
524
+ declare 'bundle exec appraisal contrib rake spec:sneakers'
525
+ declare 'bundle exec appraisal contrib rake spec:sucker_punch'
526
+ declare 'bundle exec appraisal contrib rake spec:suite'
518
527
  # Contrib specs with old gem versions
519
- sh 'bundle exec appraisal contrib-old rake spec:faraday'
528
+ declare 'bundle exec appraisal contrib-old rake spec:faraday'
520
529
  # Rails minitests
521
530
  # We only test Rails 5+ because older versions require Bundler < 2.0
522
- sh 'bundle exec appraisal rails5-mysql2 rake test:rails'
523
- sh 'bundle exec appraisal rails5-postgres rake test:rails'
524
- sh 'bundle exec appraisal rails5-postgres-redis rake spec:railsredis'
525
- sh 'bundle exec appraisal rails5-postgres-redis-activesupport rake spec:railsredis'
526
- sh 'bundle exec appraisal rails5-postgres-sidekiq rake spec:railsactivejob'
527
- sh 'bundle exec appraisal rails5-postgres rake spec:railsdisableenv'
531
+ declare 'bundle exec appraisal rails5-mysql2 rake test:rails'
532
+ declare 'bundle exec appraisal rails5-postgres rake test:rails'
533
+ declare 'bundle exec appraisal rails5-postgres-redis rake spec:railsredis'
534
+ declare 'bundle exec appraisal rails5-postgres-redis-activesupport rake spec:railsredis'
535
+ declare 'bundle exec appraisal rails5-postgres-sidekiq rake spec:railsactivejob'
536
+ declare 'bundle exec appraisal rails5-postgres rake spec:railsdisableenv'
528
537
  # Rails specs
529
- sh 'bundle exec appraisal rails5-mysql2 rake spec:rails'
530
- sh 'bundle exec appraisal rails5-postgres rake spec:rails'
538
+ declare 'bundle exec appraisal rails5-mysql2 rake spec:rails'
539
+ declare 'bundle exec appraisal rails5-postgres rake spec:rails'
531
540
  end
532
541
  elsif Gem::Version.new('2.5.0') <= Gem::Version.new(RUBY_VERSION) \
533
542
  && Gem::Version.new(RUBY_VERSION) < Gem::Version.new('2.6.0')
534
543
  # Main library
535
- sh 'bundle exec rake test:main'
536
- sh 'bundle exec rake spec:main'
537
- sh 'bundle exec rake spec:contrib'
538
- sh 'bundle exec rake spec:opentracer'
539
- sh 'bundle exec rake spec:opentelemetry'
544
+ declare 'bundle exec rake test:main'
545
+ declare 'bundle exec rake spec:main'
546
+ declare 'bundle exec rake spec:contrib'
547
+ declare 'bundle exec rake spec:opentracer'
548
+ declare 'bundle exec rake spec:opentelemetry'
540
549
  # Benchmarks
541
- sh 'bundle exec rake spec:benchmark' if RUBY_PLATFORM != 'java' # Too slow due to repeated JVM instantiation
542
- sh 'bundle exec rake benchmark'
550
+ declare 'bundle exec rake spec:benchmark' if RUBY_PLATFORM != 'java' # Too slow due to repeated JVM instantiation
551
+ declare 'bundle exec rake benchmark'
543
552
  # Contrib minitests
544
- sh 'bundle exec appraisal contrib rake test:grape'
545
- sh 'bundle exec appraisal contrib rake test:sucker_punch'
546
553
  # Contrib specs
547
- sh 'bundle exec appraisal contrib rake spec:action_pack'
548
- sh 'bundle exec appraisal contrib rake spec:action_view'
549
- sh 'bundle exec appraisal contrib rake spec:active_model_serializers'
550
- sh 'bundle exec appraisal contrib rake spec:active_record'
551
- sh 'bundle exec appraisal contrib rake spec:active_support'
552
- sh 'bundle exec appraisal contrib rake spec:aws'
553
- sh 'bundle exec appraisal contrib rake spec:concurrent_ruby'
554
- sh 'bundle exec appraisal contrib rake spec:dalli'
555
- sh 'bundle exec appraisal contrib rake spec:delayed_job'
556
- sh 'bundle exec appraisal contrib rake spec:elasticsearch'
557
- sh 'bundle exec appraisal contrib rake spec:ethon'
558
- sh 'bundle exec appraisal contrib rake spec:excon'
559
- sh 'bundle exec appraisal contrib rake spec:faraday'
560
- sh 'bundle exec appraisal contrib rake spec:grape'
561
- sh 'bundle exec appraisal contrib rake spec:graphql'
562
- sh 'bundle exec appraisal contrib rake spec:grpc' if RUBY_PLATFORM != 'java' # protobuf not supported
563
- sh 'bundle exec appraisal contrib rake spec:http'
564
- sh 'bundle exec appraisal contrib rake spec:httprb'
565
- sh 'bundle exec appraisal contrib rake spec:mongodb'
566
- sh 'bundle exec appraisal contrib rake spec:mysql2' if RUBY_PLATFORM != 'java' # built-in jdbc is used instead
567
- sh 'bundle exec appraisal contrib rake spec:presto'
568
- sh 'bundle exec appraisal contrib rake spec:racecar'
569
- sh 'bundle exec appraisal contrib rake spec:rack'
570
- sh 'bundle exec appraisal contrib rake spec:rake'
571
- sh 'bundle exec appraisal contrib rake spec:redis'
572
- sh 'bundle exec appraisal contrib rake spec:resque'
573
- sh 'bundle exec appraisal contrib rake spec:rest_client'
574
- sh 'bundle exec appraisal contrib rake spec:sequel'
575
- sh 'bundle exec appraisal contrib rake spec:shoryuken'
576
- sh 'bundle exec appraisal contrib rake spec:sidekiq'
577
- sh 'bundle exec appraisal contrib rake spec:sinatra'
578
- sh 'bundle exec appraisal contrib rake spec:sneakers'
579
- sh 'bundle exec appraisal contrib rake spec:sucker_punch'
580
- sh 'bundle exec appraisal contrib rake spec:suite'
554
+ declare 'bundle exec appraisal contrib rake spec:action_pack'
555
+ declare 'bundle exec appraisal contrib rake spec:action_view'
556
+ declare 'bundle exec appraisal contrib rake spec:active_model_serializers'
557
+ declare 'bundle exec appraisal contrib rake spec:active_record'
558
+ declare 'bundle exec appraisal contrib rake spec:active_support'
559
+ declare 'bundle exec appraisal contrib rake spec:aws'
560
+ declare 'bundle exec appraisal contrib rake spec:concurrent_ruby'
561
+ declare 'bundle exec appraisal contrib rake spec:dalli'
562
+ declare 'bundle exec appraisal contrib rake spec:delayed_job'
563
+ declare 'bundle exec appraisal contrib rake spec:elasticsearch'
564
+ declare 'bundle exec appraisal contrib rake spec:ethon'
565
+ declare 'bundle exec appraisal contrib rake spec:excon'
566
+ declare 'bundle exec appraisal contrib rake spec:faraday'
567
+ declare 'bundle exec appraisal contrib rake spec:grape'
568
+ declare 'bundle exec appraisal contrib rake spec:graphql'
569
+ declare 'bundle exec appraisal contrib rake spec:grpc' if RUBY_PLATFORM != 'java' # protobuf not supported
570
+ declare 'bundle exec appraisal contrib rake spec:http'
571
+ declare 'bundle exec appraisal contrib rake spec:httprb'
572
+ declare 'bundle exec appraisal contrib rake spec:mongodb'
573
+ declare 'bundle exec appraisal contrib rake spec:mysql2' if RUBY_PLATFORM != 'java' # built-in jdbc is used instead
574
+ declare 'bundle exec appraisal contrib rake spec:presto'
575
+ declare 'bundle exec appraisal contrib rake spec:que'
576
+ declare 'bundle exec appraisal contrib rake spec:racecar'
577
+ declare 'bundle exec appraisal contrib rake spec:rack'
578
+ declare 'bundle exec appraisal contrib rake spec:rake'
579
+ declare 'bundle exec appraisal contrib rake spec:redis'
580
+ declare 'bundle exec appraisal contrib rake spec:resque'
581
+ declare 'bundle exec appraisal contrib rake spec:rest_client'
582
+ declare 'bundle exec appraisal contrib rake spec:sequel'
583
+ declare 'bundle exec appraisal contrib rake spec:shoryuken'
584
+ declare 'bundle exec appraisal contrib rake spec:sidekiq'
585
+ declare 'bundle exec appraisal contrib rake spec:sinatra'
586
+ declare 'bundle exec appraisal contrib rake spec:sneakers'
587
+ declare 'bundle exec appraisal contrib rake spec:sucker_punch'
588
+ declare 'bundle exec appraisal contrib rake spec:suite'
581
589
  # Contrib specs with old gem versions
582
- sh 'bundle exec appraisal contrib-old rake spec:faraday'
590
+ declare 'bundle exec appraisal contrib-old rake spec:faraday'
583
591
  # Rails minitests
584
592
  # We only test Rails 5+ because older versions require Bundler < 2.0
585
- sh 'bundle exec appraisal rails5-mysql2 rake test:rails'
586
- sh 'bundle exec appraisal rails5-postgres rake test:rails'
587
- sh 'bundle exec appraisal rails5-postgres-redis rake spec:railsredis'
588
- sh 'bundle exec appraisal rails5-postgres-redis-activesupport rake spec:railsredis'
589
- sh 'bundle exec appraisal rails5-postgres-sidekiq rake spec:railsactivejob'
590
- sh 'bundle exec appraisal rails5-postgres rake spec:railsdisableenv'
591
- sh 'bundle exec appraisal rails6-mysql2 rake test:rails'
592
- sh 'bundle exec appraisal rails6-postgres rake test:rails'
593
- sh 'bundle exec appraisal rails6-postgres-redis rake spec:railsredis'
594
- sh 'bundle exec appraisal rails6-postgres-redis-activesupport rake spec:railsredis'
595
- sh 'bundle exec appraisal rails6-postgres-sidekiq rake spec:railsactivejob'
596
- sh 'bundle exec appraisal rails6-postgres rake spec:railsdisableenv'
593
+ declare 'bundle exec appraisal rails5-mysql2 rake test:rails'
594
+ declare 'bundle exec appraisal rails5-postgres rake test:rails'
595
+ declare 'bundle exec appraisal rails5-postgres-redis rake spec:railsredis'
596
+ declare 'bundle exec appraisal rails5-postgres-redis-activesupport rake spec:railsredis'
597
+ declare 'bundle exec appraisal rails5-postgres-sidekiq rake spec:railsactivejob'
598
+ declare 'bundle exec appraisal rails5-postgres rake spec:railsdisableenv'
599
+ declare 'bundle exec appraisal rails6-mysql2 rake test:rails'
600
+ declare 'bundle exec appraisal rails6-postgres rake test:rails'
601
+ declare 'bundle exec appraisal rails6-postgres-redis rake spec:railsredis'
602
+ declare 'bundle exec appraisal rails6-postgres-redis-activesupport rake spec:railsredis'
603
+ declare 'bundle exec appraisal rails6-postgres-sidekiq rake spec:railsactivejob'
604
+ declare 'bundle exec appraisal rails6-postgres rake spec:railsdisableenv'
597
605
  # Rails specs
598
- sh 'bundle exec appraisal rails5-mysql2 rake spec:action_cable'
599
- sh 'bundle exec appraisal rails5-mysql2 rake spec:rails'
600
- sh 'bundle exec appraisal rails5-postgres rake spec:rails'
601
- # sh 'bundle exec appraisal rails6-mysql2 rake spec:action_cable' # TODO: Hangs CI jobs... fix and re-enable.
602
- sh 'bundle exec appraisal rails6-mysql2 rake spec:rails'
603
- sh 'bundle exec appraisal rails6-postgres rake spec:rails'
606
+ declare 'bundle exec appraisal rails5-mysql2 rake spec:action_cable'
607
+ declare 'bundle exec appraisal rails5-mysql2 rake spec:rails'
608
+ declare 'bundle exec appraisal rails5-postgres rake spec:rails'
609
+ # declare 'bundle exec appraisal rails6-mysql2 rake spec:action_cable' # TODO: Hangs CI jobs... fix and re-enable.
610
+ declare 'bundle exec appraisal rails6-mysql2 rake spec:rails'
611
+ declare 'bundle exec appraisal rails6-postgres rake spec:rails'
604
612
  elsif Gem::Version.new('2.6.0') <= Gem::Version.new(RUBY_VERSION) \
605
613
  && Gem::Version.new(RUBY_VERSION) < Gem::Version.new('2.7.0')
606
614
  # Main library
607
- sh 'bundle exec rake test:main'
608
- sh 'bundle exec rake spec:main'
609
- sh 'bundle exec rake spec:contrib'
610
- sh 'bundle exec rake spec:opentracer'
611
- sh 'bundle exec rake spec:opentelemetry'
615
+ declare 'bundle exec rake test:main'
616
+ declare 'bundle exec rake spec:main'
617
+ declare 'bundle exec rake spec:contrib'
618
+ declare 'bundle exec rake spec:opentracer'
619
+ declare 'bundle exec rake spec:opentelemetry'
612
620
  # Benchmarks
613
- sh 'bundle exec rake spec:benchmark'
621
+ declare 'bundle exec rake spec:benchmark'
614
622
 
615
623
  if RUBY_PLATFORM != 'java'
616
624
  # Benchmarks
617
- sh 'bundle exec rake benchmark'
625
+ declare 'bundle exec rake benchmark'
618
626
  # Contrib minitests
619
- sh 'bundle exec appraisal contrib rake test:grape'
620
- sh 'bundle exec appraisal contrib rake test:sucker_punch'
621
627
  # Contrib specs
622
- sh 'bundle exec appraisal contrib rake spec:action_pack'
623
- sh 'bundle exec appraisal contrib rake spec:action_view'
624
- sh 'bundle exec appraisal contrib rake spec:active_model_serializers'
625
- sh 'bundle exec appraisal contrib rake spec:active_record'
626
- sh 'bundle exec appraisal contrib rake spec:active_support'
627
- sh 'bundle exec appraisal contrib rake spec:aws'
628
- sh 'bundle exec appraisal contrib rake spec:concurrent_ruby'
629
- sh 'bundle exec appraisal contrib rake spec:dalli'
630
- sh 'bundle exec appraisal contrib rake spec:delayed_job'
631
- sh 'bundle exec appraisal contrib rake spec:elasticsearch'
632
- sh 'bundle exec appraisal contrib rake spec:ethon'
633
- sh 'bundle exec appraisal contrib rake spec:excon'
634
- sh 'bundle exec appraisal contrib rake spec:faraday'
635
- sh 'bundle exec appraisal contrib rake spec:grape'
636
- sh 'bundle exec appraisal contrib rake spec:graphql'
637
- sh 'bundle exec appraisal contrib rake spec:grpc'
638
- sh 'bundle exec appraisal contrib rake spec:http'
639
- sh 'bundle exec appraisal contrib rake spec:httprb'
640
- sh 'bundle exec appraisal contrib rake spec:mongodb'
641
- sh 'bundle exec appraisal contrib rake spec:mysql2'
642
- sh 'bundle exec appraisal contrib rake spec:presto'
643
- sh 'bundle exec appraisal contrib rake spec:racecar'
644
- sh 'bundle exec appraisal contrib rake spec:rack'
645
- sh 'bundle exec appraisal contrib rake spec:rake'
646
- sh 'bundle exec appraisal contrib rake spec:redis'
647
- sh 'bundle exec appraisal contrib rake spec:resque'
648
- sh 'bundle exec appraisal contrib rake spec:rest_client'
649
- sh 'bundle exec appraisal contrib rake spec:sequel'
650
- sh 'bundle exec appraisal contrib rake spec:shoryuken'
651
- sh 'bundle exec appraisal contrib rake spec:sidekiq'
652
- sh 'bundle exec appraisal contrib rake spec:sinatra'
653
- sh 'bundle exec appraisal contrib rake spec:sneakers'
654
- sh 'bundle exec appraisal contrib rake spec:sucker_punch'
655
- sh 'bundle exec appraisal contrib rake spec:suite'
628
+ declare 'bundle exec appraisal contrib rake spec:action_pack'
629
+ declare 'bundle exec appraisal contrib rake spec:action_view'
630
+ declare 'bundle exec appraisal contrib rake spec:active_model_serializers'
631
+ declare 'bundle exec appraisal contrib rake spec:active_record'
632
+ declare 'bundle exec appraisal contrib rake spec:active_support'
633
+ declare 'bundle exec appraisal contrib rake spec:aws'
634
+ declare 'bundle exec appraisal contrib rake spec:concurrent_ruby'
635
+ declare 'bundle exec appraisal contrib rake spec:dalli'
636
+ declare 'bundle exec appraisal contrib rake spec:delayed_job'
637
+ declare 'bundle exec appraisal contrib rake spec:elasticsearch'
638
+ declare 'bundle exec appraisal contrib rake spec:ethon'
639
+ declare 'bundle exec appraisal contrib rake spec:excon'
640
+ declare 'bundle exec appraisal contrib rake spec:faraday'
641
+ declare 'bundle exec appraisal contrib rake spec:grape'
642
+ declare 'bundle exec appraisal contrib rake spec:graphql'
643
+ declare 'bundle exec appraisal contrib rake spec:grpc'
644
+ declare 'bundle exec appraisal contrib rake spec:http'
645
+ declare 'bundle exec appraisal contrib rake spec:httprb'
646
+ declare 'bundle exec appraisal contrib rake spec:mongodb'
647
+ declare 'bundle exec appraisal contrib rake spec:mysql2'
648
+ declare 'bundle exec appraisal contrib rake spec:presto'
649
+ declare 'bundle exec appraisal contrib rake spec:que'
650
+ declare 'bundle exec appraisal contrib rake spec:racecar'
651
+ declare 'bundle exec appraisal contrib rake spec:rack'
652
+ declare 'bundle exec appraisal contrib rake spec:rake'
653
+ declare 'bundle exec appraisal contrib rake spec:redis'
654
+ declare 'bundle exec appraisal contrib rake spec:resque'
655
+ declare 'bundle exec appraisal contrib rake spec:rest_client'
656
+ declare 'bundle exec appraisal contrib rake spec:sequel'
657
+ declare 'bundle exec appraisal contrib rake spec:shoryuken'
658
+ declare 'bundle exec appraisal contrib rake spec:sidekiq'
659
+ declare 'bundle exec appraisal contrib rake spec:sinatra'
660
+ declare 'bundle exec appraisal contrib rake spec:sneakers'
661
+ declare 'bundle exec appraisal contrib rake spec:sucker_punch'
662
+ declare 'bundle exec appraisal contrib rake spec:suite'
656
663
  # Contrib specs with old gem versions
657
- sh 'bundle exec appraisal contrib-old rake spec:faraday'
664
+ declare 'bundle exec appraisal contrib-old rake spec:faraday'
658
665
  # Rails minitests
659
666
  # We only test Rails 5+ because older versions require Bundler < 2.0
660
- sh 'bundle exec appraisal rails5-mysql2 rake test:rails'
661
- sh 'bundle exec appraisal rails5-postgres rake test:rails'
662
- sh 'bundle exec appraisal rails5-postgres-redis rake spec:railsredis'
663
- sh 'bundle exec appraisal rails5-postgres-redis-activesupport rake spec:railsredis'
664
- sh 'bundle exec appraisal rails5-postgres-sidekiq rake spec:railsactivejob'
665
- sh 'bundle exec appraisal rails5-postgres rake spec:railsdisableenv'
666
- sh 'bundle exec appraisal rails6-mysql2 rake test:rails'
667
- sh 'bundle exec appraisal rails6-postgres rake test:rails'
668
- sh 'bundle exec appraisal rails6-postgres-redis rake spec:railsredis'
669
- sh 'bundle exec appraisal rails6-postgres-redis-activesupport rake spec:railsredis'
670
- sh 'bundle exec appraisal rails6-postgres-sidekiq rake spec:railsactivejob'
671
- sh 'bundle exec appraisal rails6-postgres rake spec:railsdisableenv'
667
+ declare 'bundle exec appraisal rails5-mysql2 rake test:rails'
668
+ declare 'bundle exec appraisal rails5-postgres rake test:rails'
669
+ declare 'bundle exec appraisal rails5-postgres-redis rake spec:railsredis'
670
+ declare 'bundle exec appraisal rails5-postgres-redis-activesupport rake spec:railsredis'
671
+ declare 'bundle exec appraisal rails5-postgres-sidekiq rake spec:railsactivejob'
672
+ declare 'bundle exec appraisal rails5-postgres rake spec:railsdisableenv'
673
+ declare 'bundle exec appraisal rails6-mysql2 rake test:rails'
674
+ declare 'bundle exec appraisal rails6-postgres rake test:rails'
675
+ declare 'bundle exec appraisal rails6-postgres-redis rake spec:railsredis'
676
+ declare 'bundle exec appraisal rails6-postgres-redis-activesupport rake spec:railsredis'
677
+ declare 'bundle exec appraisal rails6-postgres-sidekiq rake spec:railsactivejob'
678
+ declare 'bundle exec appraisal rails6-postgres rake spec:railsdisableenv'
672
679
  # Rails specs
673
- sh 'bundle exec appraisal rails5-mysql2 rake spec:action_cable'
674
- sh 'bundle exec appraisal rails5-mysql2 rake spec:rails'
675
- sh 'bundle exec appraisal rails5-postgres rake spec:rails'
676
- # sh 'bundle exec appraisal rails6-mysql2 rake spec:action_cable' # TODO: Hangs CI jobs... fix and re-enable.
677
- sh 'bundle exec appraisal rails6-mysql2 rake spec:rails'
678
- sh 'bundle exec appraisal rails6-postgres rake spec:rails'
680
+ declare 'bundle exec appraisal rails5-mysql2 rake spec:action_cable'
681
+ declare 'bundle exec appraisal rails5-mysql2 rake spec:rails'
682
+ declare 'bundle exec appraisal rails5-postgres rake spec:rails'
683
+ # declare 'bundle exec appraisal rails6-mysql2 rake spec:action_cable' # TODO: Hangs CI jobs... fix and re-enable.
684
+ declare 'bundle exec appraisal rails6-mysql2 rake spec:rails'
685
+ declare 'bundle exec appraisal rails6-postgres rake spec:rails'
679
686
  end
680
687
  elsif Gem::Version.new('2.7.0') <= Gem::Version.new(RUBY_VERSION)
681
688
  # Main library
682
- sh 'bundle exec rake test:main'
683
- sh 'bundle exec rake spec:main'
684
- sh 'bundle exec rake spec:contrib'
685
- sh 'bundle exec rake spec:opentracer'
686
- sh 'bundle exec rake spec:opentelemetry'
689
+ declare 'bundle exec rake test:main'
690
+ declare 'bundle exec rake spec:main'
691
+ declare 'bundle exec rake spec:contrib'
692
+ declare 'bundle exec rake spec:opentracer'
693
+ declare 'bundle exec rake spec:opentelemetry'
687
694
  # Benchmarks
688
- sh 'bundle exec rake spec:benchmark'
695
+ declare 'bundle exec rake spec:benchmark'
689
696
 
690
697
  if RUBY_PLATFORM != 'java'
691
698
  # Benchmarks
692
- sh 'bundle exec rake benchmark'
699
+ declare 'bundle exec rake benchmark'
693
700
  # Contrib minitests
694
- sh 'bundle exec appraisal contrib rake test:grape'
695
- sh 'bundle exec appraisal contrib rake test:sucker_punch'
696
701
  # Contrib specs
697
- sh 'bundle exec appraisal contrib rake spec:action_pack'
698
- sh 'bundle exec appraisal contrib rake spec:action_view'
699
- sh 'bundle exec appraisal contrib rake spec:active_model_serializers'
700
- sh 'bundle exec appraisal contrib rake spec:active_record'
701
- sh 'bundle exec appraisal contrib rake spec:active_support'
702
- sh 'bundle exec appraisal contrib rake spec:aws'
703
- sh 'bundle exec appraisal contrib rake spec:concurrent_ruby'
704
- sh 'bundle exec appraisal contrib rake spec:dalli'
705
- sh 'bundle exec appraisal contrib rake spec:delayed_job'
706
- sh 'bundle exec appraisal contrib rake spec:elasticsearch'
707
- sh 'bundle exec appraisal contrib rake spec:ethon'
708
- sh 'bundle exec appraisal contrib rake spec:excon'
709
- sh 'bundle exec appraisal contrib rake spec:faraday'
710
- sh 'bundle exec appraisal contrib rake spec:grape'
711
- sh 'bundle exec appraisal contrib rake spec:graphql'
712
- sh 'bundle exec appraisal contrib rake spec:grpc'
713
- sh 'bundle exec appraisal contrib rake spec:http'
714
- sh 'bundle exec appraisal contrib rake spec:httprb'
715
- sh 'bundle exec appraisal contrib rake spec:mongodb'
716
- sh 'bundle exec appraisal contrib rake spec:mysql2'
717
- sh 'bundle exec appraisal contrib rake spec:presto'
718
- sh 'bundle exec appraisal contrib rake spec:racecar'
719
- sh 'bundle exec appraisal contrib rake spec:rack'
720
- sh 'bundle exec appraisal contrib rake spec:rake'
721
- sh 'bundle exec appraisal contrib rake spec:redis'
722
- sh 'bundle exec appraisal contrib rake spec:resque'
723
- sh 'bundle exec appraisal contrib rake spec:rest_client'
724
- sh 'bundle exec appraisal contrib rake spec:sequel'
725
- sh 'bundle exec appraisal contrib rake spec:shoryuken'
726
- sh 'bundle exec appraisal contrib rake spec:sidekiq'
727
- sh 'bundle exec appraisal contrib rake spec:sinatra'
728
- sh 'bundle exec appraisal contrib rake spec:sneakers'
729
- sh 'bundle exec appraisal contrib rake spec:sucker_punch'
730
- sh 'bundle exec appraisal contrib rake spec:suite'
702
+ declare 'bundle exec appraisal contrib rake spec:action_pack'
703
+ declare 'bundle exec appraisal contrib rake spec:action_view'
704
+ declare 'bundle exec appraisal contrib rake spec:active_model_serializers'
705
+ declare 'bundle exec appraisal contrib rake spec:active_record'
706
+ declare 'bundle exec appraisal contrib rake spec:active_support'
707
+ declare 'bundle exec appraisal contrib rake spec:aws'
708
+ declare 'bundle exec appraisal contrib rake spec:concurrent_ruby'
709
+ declare 'bundle exec appraisal contrib rake spec:dalli'
710
+ declare 'bundle exec appraisal contrib rake spec:delayed_job'
711
+ declare 'bundle exec appraisal contrib rake spec:elasticsearch'
712
+ declare 'bundle exec appraisal contrib rake spec:ethon'
713
+ declare 'bundle exec appraisal contrib rake spec:excon'
714
+ declare 'bundle exec appraisal contrib rake spec:faraday'
715
+ declare 'bundle exec appraisal contrib rake spec:grape'
716
+ declare 'bundle exec appraisal contrib rake spec:graphql'
717
+ declare 'bundle exec appraisal contrib rake spec:grpc'
718
+ declare 'bundle exec appraisal contrib rake spec:http'
719
+ declare 'bundle exec appraisal contrib rake spec:httprb'
720
+ declare 'bundle exec appraisal contrib rake spec:mongodb'
721
+ declare 'bundle exec appraisal contrib rake spec:mysql2'
722
+ declare 'bundle exec appraisal contrib rake spec:presto'
723
+ declare 'bundle exec appraisal contrib rake spec:que'
724
+ declare 'bundle exec appraisal contrib rake spec:racecar'
725
+ declare 'bundle exec appraisal contrib rake spec:rack'
726
+ declare 'bundle exec appraisal contrib rake spec:rake'
727
+ declare 'bundle exec appraisal contrib rake spec:redis'
728
+ declare 'bundle exec appraisal contrib rake spec:resque'
729
+ declare 'bundle exec appraisal contrib rake spec:rest_client'
730
+ declare 'bundle exec appraisal contrib rake spec:sequel'
731
+ declare 'bundle exec appraisal contrib rake spec:shoryuken'
732
+ declare 'bundle exec appraisal contrib rake spec:sidekiq'
733
+ declare 'bundle exec appraisal contrib rake spec:sinatra'
734
+ declare 'bundle exec appraisal contrib rake spec:sneakers'
735
+ declare 'bundle exec appraisal contrib rake spec:sucker_punch'
736
+ declare 'bundle exec appraisal contrib rake spec:suite'
731
737
  # Contrib specs with old gem versions
732
- sh 'bundle exec appraisal contrib-old rake spec:faraday'
738
+ declare 'bundle exec appraisal contrib-old rake spec:faraday'
733
739
  # Rails minitests
734
740
  # We only test Rails 5+ because older versions require Bundler < 2.0
735
- sh 'bundle exec appraisal rails5-mysql2 rake test:rails'
736
- sh 'bundle exec appraisal rails5-postgres rake test:rails'
737
- sh 'bundle exec appraisal rails5-postgres-redis rake spec:railsredis'
738
- sh 'bundle exec appraisal rails5-postgres-redis-activesupport rake spec:railsredis'
739
- sh 'bundle exec appraisal rails5-postgres-sidekiq rake spec:railsactivejob'
740
- sh 'bundle exec appraisal rails5-postgres rake spec:railsdisableenv'
741
- sh 'bundle exec appraisal rails6-mysql2 rake test:rails'
742
- sh 'bundle exec appraisal rails6-postgres rake test:rails'
743
- sh 'bundle exec appraisal rails6-postgres-redis rake spec:railsredis'
744
- sh 'bundle exec appraisal rails6-postgres-redis-activesupport rake spec:railsredis'
745
- sh 'bundle exec appraisal rails6-postgres-sidekiq rake spec:railsactivejob'
746
- sh 'bundle exec appraisal rails6-postgres rake spec:railsdisableenv'
741
+ declare 'bundle exec appraisal rails5-mysql2 rake test:rails'
742
+ declare 'bundle exec appraisal rails5-postgres rake test:rails'
743
+ declare 'bundle exec appraisal rails5-postgres-redis rake spec:railsredis'
744
+ declare 'bundle exec appraisal rails5-postgres-redis-activesupport rake spec:railsredis'
745
+ declare 'bundle exec appraisal rails5-postgres-sidekiq rake spec:railsactivejob'
746
+ declare 'bundle exec appraisal rails5-postgres rake spec:railsdisableenv'
747
+ declare 'bundle exec appraisal rails6-mysql2 rake test:rails'
748
+ declare 'bundle exec appraisal rails6-postgres rake test:rails'
749
+ declare 'bundle exec appraisal rails6-postgres-redis rake spec:railsredis'
750
+ declare 'bundle exec appraisal rails6-postgres-redis-activesupport rake spec:railsredis'
751
+ declare 'bundle exec appraisal rails6-postgres-sidekiq rake spec:railsactivejob'
752
+ declare 'bundle exec appraisal rails6-postgres rake spec:railsdisableenv'
747
753
  # Rails specs
748
- sh 'bundle exec appraisal rails5-mysql2 rake spec:rails'
749
- sh 'bundle exec appraisal rails5-postgres rake spec:rails'
750
- sh 'bundle exec appraisal rails6-mysql2 rake spec:rails'
751
- sh 'bundle exec appraisal rails6-postgres rake spec:rails'
754
+ declare 'bundle exec appraisal rails5-mysql2 rake spec:rails'
755
+ declare 'bundle exec appraisal rails5-postgres rake spec:rails'
756
+ declare 'bundle exec appraisal rails6-mysql2 rake spec:rails'
757
+ declare 'bundle exec appraisal rails6-postgres rake spec:rails'
758
+ end
759
+ end
760
+ end
761
+
762
+ namespace :coverage do
763
+ # Generates one global report for all tracer tests
764
+ task :report do
765
+ require 'simplecov'
766
+
767
+ resultset_files = Dir["#{ENV.fetch('COVERAGE_DIR', 'coverage')}/.resultset.json"] +
768
+ Dir["#{ENV.fetch('COVERAGE_DIR', 'coverage')}/versions/**/.resultset.json"]
769
+
770
+ SimpleCov.collate resultset_files do
771
+ coverage_dir "#{ENV.fetch('COVERAGE_DIR', 'coverage')}/report"
772
+ formatter SimpleCov::Formatter::HTMLFormatter
773
+ end
774
+ end
775
+
776
+ # Generates one report for each Ruby version
777
+ task :report_per_ruby_version do
778
+ require 'simplecov'
779
+
780
+ versions = Dir["#{ENV.fetch('COVERAGE_DIR', 'coverage')}/versions/*"].map { |f| File.basename(f) }
781
+ versions.map do |version|
782
+ puts "Generating report for: #{version}"
783
+ SimpleCov.collate Dir["#{ENV.fetch('COVERAGE_DIR', 'coverage')}/versions/#{version}/**/.resultset.json"] do
784
+ coverage_dir "#{ENV.fetch('COVERAGE_DIR', 'coverage')}/report/versions/#{version}"
785
+ formatter SimpleCov::Formatter::HTMLFormatter
786
+ end
752
787
  end
753
788
  end
754
789
  end