aboutsummaryrefslogtreecommitdiffstats
path: root/activesupport/test
diff options
context:
space:
mode:
authorRick Olson <technoweenie@gmail.com>2007-05-29 09:10:36 +0000
committerRick Olson <technoweenie@gmail.com>2007-05-29 09:10:36 +0000
commit0345c975879e352a5726ff9f91258fdb3afe8525 (patch)
treecd756b9bbaba74250d8ade5a138fcde70f1ce386 /activesupport/test
parentae242b0d23df2893f398fb2ec97ba502b7bf361b (diff)
downloadrails-0345c975879e352a5726ff9f91258fdb3afe8525.tar.gz
rails-0345c975879e352a5726ff9f91258fdb3afe8525.tar.bz2
rails-0345c975879e352a5726ff9f91258fdb3afe8525.zip
escape <'s and >'s in JSON strings. #8371 [Rick]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6893 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'activesupport/test')
-rw-r--r--activesupport/test/json/encoding_test.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/activesupport/test/json/encoding_test.rb b/activesupport/test/json/encoding_test.rb
index 3c0e0bc6b2..9ed7683b86 100644
--- a/activesupport/test/json/encoding_test.rb
+++ b/activesupport/test/json/encoding_test.rb
@@ -13,7 +13,7 @@ class TestJSONEncoding < Test::Unit::TestCase
NumericTests = [[ 1, %(1) ],
[ 2.5, %(2.5) ]]
- StringTests = [[ 'this is the string', %("this is the string") ],
+ StringTests = [[ 'this is the <string>', %("this is the \\074string\\076")],
[ 'a "string" with quotes', %("a \\"string\\" with quotes") ]]
ArrayTests = [[ ['a', 'b', 'c'], %([\"a\", \"b\", \"c\"]) ],