Skip to content

Commit

Permalink
Use strip_heredoc for deprecation warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
znz committed Sep 4, 2016
1 parent 4c3838b commit 9fe7040
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib/devise/test/controller_helpers.rb
Expand Up @@ -65,7 +65,7 @@ def sign_in(resource, deprecated = nil, scope: nil)
scope = resource
resource = deprecated

ActiveSupport::Deprecation.warn <<-DEPRECATION
ActiveSupport::Deprecation.warn <<-DEPRECATION.strip_heredoc
[Devise] sign_in(:#{scope}, resource) on controller tests is deprecated and will be removed from Devise.
Please use sign_in(resource, scope: :#{scope}) instead.
DEPRECATION
Expand Down
2 changes: 1 addition & 1 deletion lib/devise/test_helpers.rb
Expand Up @@ -2,7 +2,7 @@ module Devise
module TestHelpers
def self.included(base)
base.class_eval do
ActiveSupport::Deprecation.warn <<-DEPRECATION
ActiveSupport::Deprecation.warn <<-DEPRECATION.strip_heredoc
[Devise] including `Devise::TestHelpers` is deprecated and will be removed from Devise.
For controller tests, please include `Devise::Test::ControllerHelpers` instead.
DEPRECATION
Expand Down

0 comments on commit 9fe7040

Please sign in to comment.