Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialShan Lin
6,183 PointsHow to configure 'config.raise_errors_for_deprecations!'
There is a message showing up every time when I'm doing the rspec test on terminal,
"If you need more of the backtrace for any of these deprecations to
identify where to make the necessary changes, you can configure
config.raise_errors_for_deprecations!
, and it will turn the
deprecation warnings into errors, giving you the full backtrace."
I tried to add 'config.raise_errors_for_deprecations!', there is an error. I tried 'config.raise_errors_for_deprecations = true' and 'config.active_support.deprecation = :raise' still not solve the problem.
1 Answer
Jason Seifer
Treehouse Guest TeacherHey Shan Lin that is a message with RSpec 3. The config line belongs in the Rspec.configure do |config|
block in your rails_helper.rb
(spec_helper.rb
replacement) file.