spec/gon/global_spec.rb in gon-4.1.0 vs spec/gon/global_spec.rb in gon-4.1.1
- old
+ new
@@ -81,10 +81,10 @@
it 'outputs correct js with a script string' do
Gon.global.str = %q(</script><script>alert('!')</script>)
@base.include_gon.should == "<script type=\"text/javascript\">" +
"\n//<![CDATA[\n" +
"window.gon = {};" +
- "gon.global={\"str\":\"</script><script>alert('!')</script>\"};" +
+ "gon.global={\"str\":\"\\u003C/script><script>alert('!')\\u003C/script>\"};" +
"\n//]]>\n" +
"</script>"
end
it 'outputs correct js with a unicode line separator' do