1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00

Remove deprecated ActiveSupport::SafeBuffer#prepend

This commit is contained in:
Rafael Mendonça França 2015-01-02 22:13:27 -03:00
parent 481e49c64f
commit e1c8b9f688
3 changed files with 4 additions and 16 deletions

View file

@ -1,3 +1,7 @@
* Remove deprecated `ActiveSupport::SafeBuffer#prepend`.
*Rafael Mendonça França*
* Remove deprecated methods at `Kernel`.
`silence_stderr`, `silence_stream`, `capture` and `quietly`.

View file

@ -1,6 +1,5 @@
require 'erb'
require 'active_support/core_ext/kernel/singleton_class'
require 'active_support/deprecation'
class ERB
module Util
@ -190,11 +189,6 @@ module ActiveSupport #:nodoc:
super(html_escape_interpolated_argument(value))
end
def prepend!(value)
ActiveSupport::Deprecation.deprecation_warning "ActiveSupport::SafeBuffer#prepend!", :prepend
prepend value
end
def +(other)
dup.concat(other)
end

View file

@ -667,16 +667,6 @@ class OutputSafetyTest < ActiveSupport::TestCase
assert_equal other, "&lt;foo&gt;other"
end
test "Deprecated #prepend! method is still present" do
other = "other".html_safe
assert_deprecated do
other.prepend! "<foo>"
end
assert_equal other, "&lt;foo&gt;other"
end
test "Concatting safe onto unsafe yields unsafe" do
@other_string = "other"