You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by kk...@apache.org on 2010/02/04 13:16:53 UTC

svn commit: r906464 - in /tomcat/trunk/test: org/apache/el/TestELInJsp.java webapp/el-misc.jsp

Author: kkolinko
Date: Thu Feb  4 12:16:51 2010
New Revision: 906464

URL: http://svn.apache.org/viewvc?rev=906464&view=rev
Log:
Test for a bug with processing of double quotes in AttributeParser#parseEL

Modified:
    tomcat/trunk/test/org/apache/el/TestELInJsp.java
    tomcat/trunk/test/webapp/el-misc.jsp

Modified: tomcat/trunk/test/org/apache/el/TestELInJsp.java
URL: http://svn.apache.org/viewvc/tomcat/trunk/test/org/apache/el/TestELInJsp.java?rev=906464&r1=906463&r2=906464&view=diff
==============================================================================
--- tomcat/trunk/test/org/apache/el/TestELInJsp.java (original)
+++ tomcat/trunk/test/org/apache/el/TestELInJsp.java Thu Feb  4 12:16:51 2010
@@ -322,6 +322,7 @@
         ByteChunk res = getUrl("http://localhost:" + getPort() +
                 "/test/el-misc.jsp");
         String result = res.toString();
+        System.out.println(result);
         assertEcho(result, "00-\\\\\\\"${'hello world'}");
         assertEcho(result, "01-\\\\\\\"\\${'hello world'}");
         assertEcho(result, "02-\\\"${'hello world'}");
@@ -334,6 +335,12 @@
         assertEcho(result, "09-az2");
         assertEcho(result, "10-${'foo'}bar");
         assertEcho(result, "11-\"}");
+        assertEcho(result, "12-foo\\bar\\baz");
+        assertEcho(result, "13-foo\\bar\\baz");
+        assertEcho(result, "14-foo\\bar\\baz");
+        assertEcho(result, "15-foo\\bar\\baz");
+        assertEcho(result, "16-foo\\bar\\baz");
+        assertEcho(result, "17-foo\\bar\\baz");
     }
 
     public void testScriptingExpression() throws Exception {

Modified: tomcat/trunk/test/webapp/el-misc.jsp
URL: http://svn.apache.org/viewvc/tomcat/trunk/test/webapp/el-misc.jsp?rev=906464&r1=906463&r2=906464&view=diff
==============================================================================
--- tomcat/trunk/test/webapp/el-misc.jsp (original)
+++ tomcat/trunk/test/webapp/el-misc.jsp Thu Feb  4 12:16:51 2010
@@ -30,5 +30,11 @@
     <tags:echo echo="09-az${\"2\"}" />
     <tags:echo echo="10-\${'foo'}${'bar'}" />
     <tags:echo echo="11-${\"\\\"}\"}" />
+    <tags:echo echo="12-${'foo'}\\${'bar'}\\${'baz'}" />
+    <tags:echo echo="13-${'foo'}\\${\"bar\"}\\${'baz'}" />
+    <tags:echo echo="14-${\"foo\"}\\${'bar'}\\${\"baz\"}" />
+    <tags:echo echo='15-${\'foo\'}\\${"bar"}\\${\'baz\'}' />
+    <tags:echo echo='16-${"foo"}\\${\'bar\'}\\${"baz"}' />
+    <tags:echo echo='17-${"foo"}\\${&apos;bar&apos;}\\${&quot;baz&quot;}' />
   </body>
 </html>
\ No newline at end of file



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org