aboutsummaryrefslogtreecommitdiffstats
path: root/activejob/test/helper.rb
diff options
context:
space:
mode:
authorclaudiob <claudiob@gmail.com>2015-08-27 14:21:00 -0700
committerclaudiob <claudiob@gmail.com>2015-08-31 00:30:53 -0700
commit5e9a3e12928f162492a84576763c712953534ae6 (patch)
tree59db553c2a2ae27878920225fcde04deafbe9cbb /activejob/test/helper.rb
parent13c690345152b8ec33919a69d6a290eed571a378 (diff)
downloadrails-5e9a3e12928f162492a84576763c712953534ae6.tar.gz
rails-5e9a3e12928f162492a84576763c712953534ae6.tar.bz2
rails-5e9a3e12928f162492a84576763c712953534ae6.zip
Silence callback deprecation warning if testing AJ
Currently the log returned by running ActiveJob tests is filled with: > DEPRECATION WARNING: Returning `false` in a callback will not implicitly halt a callback chain in the next release of Rails. To explicitly halt a callback chain, please use `throw :abort` instead. For instance, see https://travis-ci.org/rails/rails/builds/77978273 This happens because some setup and teardown methods [like these one](https://github.com/rails/rails/blob/master/activejob/test/cases/async_job_test.rb#L10-L17) invoke other methods like `perform_asynchronously!` that can return `false`, but not with the intention of halting the process if they do. In my opinion, these deprecation warnings can be silenced to have the log result cleaner (especially when browsing for errors).
Diffstat (limited to 'activejob/test/helper.rb')
-rw-r--r--activejob/test/helper.rb1
1 files changed, 1 insertions, 0 deletions
diff --git a/activejob/test/helper.rb b/activejob/test/helper.rb
index 57907042d9..55f690bda8 100644
--- a/activejob/test/helper.rb
+++ b/activejob/test/helper.rb
@@ -3,6 +3,7 @@ require File.expand_path('../../../load_paths', __FILE__)
require 'active_job'
require 'support/job_buffer'
+ActiveSupport.halt_callback_chains_on_return_false = false
GlobalID.app = 'aj'
@adapter = ENV['AJ_ADAPTER'] || 'inline'