aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/test
diff options
context:
space:
mode:
authorbenmmurphy <benmmurphy@gmail.com>2012-02-22 16:11:03 +0000
committerBen Murphy <benmmurphy@gmail.com>2012-03-11 17:28:02 +0000
commitc8168a7cdcdda114f634e8a429ba7ebac86eaf18 (patch)
tree832afe6d612a8f60fe606b6fa07bc778f8896e5c /actionpack/test
parent4d2d0d9906f16a1255e10d55530907318b281c3e (diff)
downloadrails-c8168a7cdcdda114f634e8a429ba7ebac86eaf18.tar.gz
rails-c8168a7cdcdda114f634e8a429ba7ebac86eaf18.tar.bz2
rails-c8168a7cdcdda114f634e8a429ba7ebac86eaf18.zip
ensure u2029 is escaped in escape_javascript helper
Diffstat (limited to 'actionpack/test')
-rw-r--r--actionpack/test/template/javascript_helper_test.rb2
1 files changed, 2 insertions, 0 deletions
diff --git a/actionpack/test/template/javascript_helper_test.rb b/actionpack/test/template/javascript_helper_test.rb
index 9441bd6b38..64898f7ad1 100644
--- a/actionpack/test/template/javascript_helper_test.rb
+++ b/actionpack/test/template/javascript_helper_test.rb
@@ -28,6 +28,8 @@ class JavaScriptHelperTest < ActionView::TestCase
assert_equal %(backslash\\\\test), escape_javascript( %(backslash\\test) )
assert_equal %(dont <\\/close> tags), escape_javascript(%(dont </close> tags))
assert_equal %(unicode &#x2028; newline), escape_javascript(%(unicode \342\200\250 newline).force_encoding('UTF-8').encode!)
+ assert_equal %(unicode &#x2029; newline), escape_javascript(%(unicode \342\200\251 newline).force_encoding('UTF-8').encode!)
+
assert_equal %(dont <\\/close> tags), j(%(dont </close> tags))
end