Rename no-el to el-as-literal
authormarkt <markt@13f79535-47bb-0310-9956-ffa450edef68>
Sun, 7 Mar 2010 20:51:34 +0000 (20:51 +0000)
committermarkt <markt@13f79535-47bb-0310-9956-ffa450edef68>
Sun, 7 Mar 2010 20:51:34 +0000 (20:51 +0000)
Add tests for 2.3, 2.4 & 2.5 webapps with Tag libraries that require various JSP versions
These currently all work and I think some should fail - looking into that next

git-svn-id: https://svn.apache.org/repos/asf/tomcat/trunk@920109 13f79535-47bb-0310-9956-ffa450edef68

24 files changed:
test/org/apache/jasper/compiler/TestJspConfig.java
test/org/apache/jasper/compiler/TestValidator.java
test/webapp-2.3/WEB-INF/tags11.tld [new file with mode: 0644]
test/webapp-2.3/WEB-INF/tags12.tld [new file with mode: 0644]
test/webapp-2.3/WEB-INF/tags20.tld [new file with mode: 0644]
test/webapp-2.3/WEB-INF/tags21.tld [new file with mode: 0644]
test/webapp-2.3/el-as-literal.jsp [new file with mode: 0644]
test/webapp-2.3/no-el.jsp [deleted file]
test/webapp-2.3/tld-versions.jsp [new file with mode: 0644]
test/webapp-2.4/WEB-INF/tags11.tld [new file with mode: 0644]
test/webapp-2.4/WEB-INF/tags12.tld [new file with mode: 0644]
test/webapp-2.4/WEB-INF/tags20.tld [new file with mode: 0644]
test/webapp-2.4/WEB-INF/tags21.tld [new file with mode: 0644]
test/webapp-2.4/WEB-INF/web.xml [new file with mode: 0644]
test/webapp-2.4/el-as-literal.jsp [new file with mode: 0644]
test/webapp-2.4/tld-versions.jsp [new file with mode: 0644]
test/webapp-2.5/WEB-INF/tags11.tld [new file with mode: 0644]
test/webapp-2.5/WEB-INF/tags12.tld [new file with mode: 0644]
test/webapp-2.5/WEB-INF/tags20.tld [new file with mode: 0644]
test/webapp-2.5/WEB-INF/tags21.tld [new file with mode: 0644]
test/webapp-2.5/WEB-INF/web.xml [new file with mode: 0644]
test/webapp-2.5/el-as-literal.jsp [new file with mode: 0644]
test/webapp-2.5/tld-versions.jsp [new file with mode: 0644]
test/webapp-3.0/el-as-literal.jsp [new file with mode: 0644]

index 0695aa9..cab6f85 100644 (file)
@@ -36,7 +36,7 @@ public class TestJspConfig extends TomcatBaseTest {
         tomcat.start();
 
         ByteChunk res = getUrl("http://localhost:" + getPort() +
-                "/test/no-el.jsp");
+                "/test/el-as-literal.jsp");
 
         String result = res.toString();
         
@@ -44,4 +44,59 @@ public class TestJspConfig extends TomcatBaseTest {
         assertTrue(result.indexOf("<p>01-#{'hello world'}</p>") > 0);
     }
 
+    public void testServlet24NoEL() throws Exception {
+        Tomcat tomcat = getTomcatInstance();
+
+        File appDir = 
+            new File("test/webapp-2.4");
+        // app dir is relative to server home
+        tomcat.addWebapp(null, "/test", appDir.getAbsolutePath());
+        
+        tomcat.start();
+
+        ByteChunk res = getUrl("http://localhost:" + getPort() +
+                "/test/el-as-literal.jsp");
+
+        String result = res.toString();
+        
+        assertTrue(result.indexOf("<p>00-hello world</p>") > 0);
+        assertTrue(result.indexOf("<p>01-#{'hello world'}</p>") > 0);
+    }
+
+    public void testServlet25NoEL() throws Exception {
+        Tomcat tomcat = getTomcatInstance();
+
+        File appDir = 
+            new File("test/webapp-2.5");
+        // app dir is relative to server home
+        tomcat.addWebapp(null, "/test", appDir.getAbsolutePath());
+        
+        tomcat.start();
+
+        ByteChunk res = getUrl("http://localhost:" + getPort() +
+                "/test/el-as-literal.jsp");
+
+        String result = res.toString();
+        
+        assertTrue(result.indexOf("<p>00-hello world</p>") > 0);
+    }
+
+    public void testServlet30NoEL() throws Exception {
+        Tomcat tomcat = getTomcatInstance();
+
+        File appDir = 
+            new File("test/webapp-3.0");
+        // app dir is relative to server home
+        tomcat.addWebapp(null, "/test", appDir.getAbsolutePath());
+        
+        tomcat.start();
+
+        ByteChunk res = getUrl("http://localhost:" + getPort() +
+                "/test/el-as-literal.jsp");
+
+        String result = res.toString();
+        
+        assertTrue(result.indexOf("<p>00-hello world</p>") > 0);
+    }
+
 }
index c2a74e5..dd1d08d 100644 (file)
@@ -51,6 +51,81 @@ public class TestValidator extends TomcatBaseTest {
     }
     
 
+    public void testTldVersions23() throws Exception {
+        Tomcat tomcat = getTomcatInstance();
+
+        File appDir = 
+            new File("test/webapp-2.3");
+        // app dir is relative to server home
+        tomcat.addWebapp(null, "/test", appDir.getAbsolutePath());
+        
+        tomcat.start();
+
+        ByteChunk res = getUrl("http://localhost:" + getPort() +
+                "/test/tld-versions.jsp");
+
+        String result = res.toString();
+
+        assertTrue(result.indexOf("<p>${'00-hello world'}</p>") > 0);
+        assertTrue(result.indexOf("<p>#{'01-hello world'}</p>") > 0);
+        assertTrue(result.indexOf("<p>${'02-hello world'}</p>") > 0);
+        assertTrue(result.indexOf("<p>#{'03-hello world'}</p>") > 0);
+        assertTrue(result.indexOf("<p>${'04-hello world'}</p>") > 0);
+        assertTrue(result.indexOf("<p>#{'05-hello world'}</p>") > 0);
+        assertTrue(result.indexOf("<p>${'06-hello world'}</p>") > 0);
+    }
+
+    
+    public void testTldVersions24() throws Exception {
+        Tomcat tomcat = getTomcatInstance();
+
+        File appDir = 
+            new File("test/webapp-2.4");
+        // app dir is relative to server home
+        tomcat.addWebapp(null, "/test", appDir.getAbsolutePath());
+        
+        tomcat.start();
+
+        ByteChunk res = getUrl("http://localhost:" + getPort() +
+                "/test/tld-versions.jsp");
+
+        String result = res.toString();
+
+        assertTrue(result.indexOf("<p>${'00-hello world'}</p>") > 0);
+        assertTrue(result.indexOf("<p>#{'01-hello world'}</p>") > 0);
+        assertTrue(result.indexOf("<p>${'02-hello world'}</p>") > 0);
+        assertTrue(result.indexOf("<p>#{'03-hello world'}</p>") > 0);
+        assertTrue(result.indexOf("<p>04-hello world</p>") > 0);
+        assertTrue(result.indexOf("<p>#{'05-hello world'}</p>") > 0);
+        assertTrue(result.indexOf("<p>06-hello world</p>") > 0);
+    }
+
+    
+    public void testTldVersions25() throws Exception {
+        Tomcat tomcat = getTomcatInstance();
+
+        File appDir = 
+            new File("test/webapp-2.5");
+        // app dir is relative to server home
+        tomcat.addWebapp(null, "/test", appDir.getAbsolutePath());
+        
+        tomcat.start();
+
+        ByteChunk res = getUrl("http://localhost:" + getPort() +
+                "/test/tld-versions.jsp");
+
+        String result = res.toString();
+
+        assertTrue(result.indexOf("<p>${'00-hello world'}</p>") > 0);
+        assertTrue(result.indexOf("<p>#{'01-hello world'}</p>") > 0);
+        assertTrue(result.indexOf("<p>${'02-hello world'}</p>") > 0);
+        assertTrue(result.indexOf("<p>#{'03-hello world'}</p>") > 0);
+        assertTrue(result.indexOf("<p>04-hello world</p>") > 0);
+        assertTrue(result.indexOf("<p>#{'05-hello world'}</p>") > 0);
+        assertTrue(result.indexOf("<p>06-hello world</p>") > 0);
+    }
+
+    
     public void testTldVersions30() throws Exception {
         Tomcat tomcat = getTomcatInstance();
 
diff --git a/test/webapp-2.3/WEB-INF/tags11.tld b/test/webapp-2.3/WEB-INF/tags11.tld
new file mode 100644 (file)
index 0000000..b78be03
--- /dev/null
@@ -0,0 +1,36 @@
+<?xml version="1.0" encoding="ISO-8859-1" ?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+--><!DOCTYPE taglib
+      PUBLIC "-//Sun Microsystems, Inc.//DTD JSP Tag Library 1.1//EN"
+      "http://java.sun.com/dtd/web-jsptaglibrary_1_1.dtd">
+<taglib>
+  <tlibversion>1.0</tlibversion>
+  <jspversion>1.1</jspversion>
+  <shortname>Tags11</shortname>
+  <uri>http://tomcat.apache.org/tags11</uri>
+
+  <tag>
+    <name>Echo</name>
+    <tagclass>org.apache.jasper.compiler.TestValidator$Echo</tagclass>
+    <bodycontent>empty</bodycontent>
+    <attribute>
+      <name>echo</name>
+      <required>yes</required>
+    </attribute>
+  </tag>
+
+</taglib>
\ No newline at end of file
diff --git a/test/webapp-2.3/WEB-INF/tags12.tld b/test/webapp-2.3/WEB-INF/tags12.tld
new file mode 100644 (file)
index 0000000..55908d9
--- /dev/null
@@ -0,0 +1,36 @@
+<?xml version="1.0" encoding="ISO-8859-1" ?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+--><!DOCTYPE taglib
+      PUBLIC "-//Sun Microsystems, Inc.//DTD JSP Tag Library 1.2//EN"
+      "http://java.sun.com/dtd/web-jsptaglibrary_1_2.dtd">
+<taglib>
+  <tlib-version>1.0</tlib-version>
+  <jsp-version>1.2</jsp-version>
+  <short-name>Tags12</short-name>
+  <uri>http://tomcat.apache.org/tags12</uri>
+
+  <tag>
+    <name>Echo</name>
+    <tagclass>org.apache.jasper.compiler.TestValidator$Echo</tagclass>
+    <body-content>empty</body-content>
+    <attribute>
+      <name>echo</name>
+      <required>yes</required>
+    </attribute>
+  </tag>
+
+</taglib>
\ No newline at end of file
diff --git a/test/webapp-2.3/WEB-INF/tags20.tld b/test/webapp-2.3/WEB-INF/tags20.tld
new file mode 100644 (file)
index 0000000..9130867
--- /dev/null
@@ -0,0 +1,37 @@
+<?xml version="1.0" encoding="ISO-8859-1" ?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+--><taglib xmlns="http://java.sun.com/xml/ns/javaee"
+      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+      xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
+      http://java.sun.com/xml/ns/javaee/web-jsptaglibrary_2_0.xsd"
+      version="2.0">
+  <tlib-version>1.0</tlib-version>
+  <short-name>Tags20</short-name>
+  <uri>http://tomcat.apache.org/tags20</uri>
+
+  <tag>
+    <name>Echo</name>
+    <tagclass>org.apache.jasper.compiler.TestValidator$Echo</tagclass>
+    <body-content>empty</body-content>
+    <attribute>
+      <name>echo</name>
+      <required>yes</required>
+      <rtexprvalue>true</rtexprvalue>
+    </attribute>
+  </tag>
+
+</taglib>
\ No newline at end of file
diff --git a/test/webapp-2.3/WEB-INF/tags21.tld b/test/webapp-2.3/WEB-INF/tags21.tld
new file mode 100644 (file)
index 0000000..7b8c3c5
--- /dev/null
@@ -0,0 +1,37 @@
+<?xml version="1.0" encoding="ISO-8859-1" ?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+--><taglib xmlns="http://java.sun.com/xml/ns/javaee"
+      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+      xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
+      http://java.sun.com/xml/ns/javaee/web-jsptaglibrary_2_1.xsd"
+      version="2.1">
+  <tlib-version>1.0</tlib-version>
+  <short-name>Tags21</short-name>
+  <uri>http://tomcat.apache.org/tags21</uri>
+
+  <tag>
+    <name>Echo</name>
+    <tagclass>org.apache.jasper.compiler.TestValidator$Echo</tagclass>
+    <body-content>empty</body-content>
+    <attribute>
+      <name>echo</name>
+      <required>yes</required>
+      <rtexprvalue>true</rtexprvalue>
+    </attribute>
+  </tag>
+
+</taglib>
\ No newline at end of file
diff --git a/test/webapp-2.3/el-as-literal.jsp b/test/webapp-2.3/el-as-literal.jsp
new file mode 100644 (file)
index 0000000..9b47cc0
--- /dev/null
@@ -0,0 +1,22 @@
+<%--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+--%>
+<html>
+  <body>
+    <p>00-${'hello world'}</p>
+    <p>01-#{'hello world'}</p>
+  </body>
+</html>
\ No newline at end of file
diff --git a/test/webapp-2.3/no-el.jsp b/test/webapp-2.3/no-el.jsp
deleted file mode 100644 (file)
index 9b47cc0..0000000
+++ /dev/null
@@ -1,22 +0,0 @@
-<%--
- Licensed to the Apache Software Foundation (ASF) under one or more
-  contributor license agreements.  See the NOTICE file distributed with
-  this work for additional information regarding copyright ownership.
-  The ASF licenses this file to You under the Apache License, Version 2.0
-  (the "License"); you may not use this file except in compliance with
-  the License.  You may obtain a copy of the License at
-
-      http://www.apache.org/licenses/LICENSE-2.0
-
-  Unless required by applicable law or agreed to in writing, software
-  distributed under the License is distributed on an "AS IS" BASIS,
-  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-  See the License for the specific language governing permissions and
-  limitations under the License.
---%>
-<html>
-  <body>
-    <p>00-${'hello world'}</p>
-    <p>01-#{'hello world'}</p>
-  </body>
-</html>
\ No newline at end of file
diff --git a/test/webapp-2.3/tld-versions.jsp b/test/webapp-2.3/tld-versions.jsp
new file mode 100644 (file)
index 0000000..debf250
--- /dev/null
@@ -0,0 +1,29 @@
+<%--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+--%>
+<html><body>
+<%@ taglib prefix="tags11" uri="http://tomcat.apache.org/tags11" %>
+<%@ taglib prefix="tags12" uri="http://tomcat.apache.org/tags12" %>
+<%@ taglib prefix="tags20" uri="http://tomcat.apache.org/tags20" %>
+<%@ taglib prefix="tags21" uri="http://tomcat.apache.org/tags21" %>
+<tags11:Echo echo="${'00-hello world'}"/>
+<tags11:Echo echo="#{'01-hello world'}"/>
+<tags12:Echo echo="${'02-hello world'}"/>
+<tags12:Echo echo="#{'03-hello world'}"/>
+<tags20:Echo echo="${'04-hello world'}"/>
+<tags20:Echo echo="#{'05-hello world'}"/>
+<tags21:Echo echo="${'06-hello world'}"/>
+</body></html>
\ No newline at end of file
diff --git a/test/webapp-2.4/WEB-INF/tags11.tld b/test/webapp-2.4/WEB-INF/tags11.tld
new file mode 100644 (file)
index 0000000..b78be03
--- /dev/null
@@ -0,0 +1,36 @@
+<?xml version="1.0" encoding="ISO-8859-1" ?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+--><!DOCTYPE taglib
+      PUBLIC "-//Sun Microsystems, Inc.//DTD JSP Tag Library 1.1//EN"
+      "http://java.sun.com/dtd/web-jsptaglibrary_1_1.dtd">
+<taglib>
+  <tlibversion>1.0</tlibversion>
+  <jspversion>1.1</jspversion>
+  <shortname>Tags11</shortname>
+  <uri>http://tomcat.apache.org/tags11</uri>
+
+  <tag>
+    <name>Echo</name>
+    <tagclass>org.apache.jasper.compiler.TestValidator$Echo</tagclass>
+    <bodycontent>empty</bodycontent>
+    <attribute>
+      <name>echo</name>
+      <required>yes</required>
+    </attribute>
+  </tag>
+
+</taglib>
\ No newline at end of file
diff --git a/test/webapp-2.4/WEB-INF/tags12.tld b/test/webapp-2.4/WEB-INF/tags12.tld
new file mode 100644 (file)
index 0000000..55908d9
--- /dev/null
@@ -0,0 +1,36 @@
+<?xml version="1.0" encoding="ISO-8859-1" ?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+--><!DOCTYPE taglib
+      PUBLIC "-//Sun Microsystems, Inc.//DTD JSP Tag Library 1.2//EN"
+      "http://java.sun.com/dtd/web-jsptaglibrary_1_2.dtd">
+<taglib>
+  <tlib-version>1.0</tlib-version>
+  <jsp-version>1.2</jsp-version>
+  <short-name>Tags12</short-name>
+  <uri>http://tomcat.apache.org/tags12</uri>
+
+  <tag>
+    <name>Echo</name>
+    <tagclass>org.apache.jasper.compiler.TestValidator$Echo</tagclass>
+    <body-content>empty</body-content>
+    <attribute>
+      <name>echo</name>
+      <required>yes</required>
+    </attribute>
+  </tag>
+
+</taglib>
\ No newline at end of file
diff --git a/test/webapp-2.4/WEB-INF/tags20.tld b/test/webapp-2.4/WEB-INF/tags20.tld
new file mode 100644 (file)
index 0000000..9130867
--- /dev/null
@@ -0,0 +1,37 @@
+<?xml version="1.0" encoding="ISO-8859-1" ?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+--><taglib xmlns="http://java.sun.com/xml/ns/javaee"
+      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+      xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
+      http://java.sun.com/xml/ns/javaee/web-jsptaglibrary_2_0.xsd"
+      version="2.0">
+  <tlib-version>1.0</tlib-version>
+  <short-name>Tags20</short-name>
+  <uri>http://tomcat.apache.org/tags20</uri>
+
+  <tag>
+    <name>Echo</name>
+    <tagclass>org.apache.jasper.compiler.TestValidator$Echo</tagclass>
+    <body-content>empty</body-content>
+    <attribute>
+      <name>echo</name>
+      <required>yes</required>
+      <rtexprvalue>true</rtexprvalue>
+    </attribute>
+  </tag>
+
+</taglib>
\ No newline at end of file
diff --git a/test/webapp-2.4/WEB-INF/tags21.tld b/test/webapp-2.4/WEB-INF/tags21.tld
new file mode 100644 (file)
index 0000000..7b8c3c5
--- /dev/null
@@ -0,0 +1,37 @@
+<?xml version="1.0" encoding="ISO-8859-1" ?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+--><taglib xmlns="http://java.sun.com/xml/ns/javaee"
+      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+      xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
+      http://java.sun.com/xml/ns/javaee/web-jsptaglibrary_2_1.xsd"
+      version="2.1">
+  <tlib-version>1.0</tlib-version>
+  <short-name>Tags21</short-name>
+  <uri>http://tomcat.apache.org/tags21</uri>
+
+  <tag>
+    <name>Echo</name>
+    <tagclass>org.apache.jasper.compiler.TestValidator$Echo</tagclass>
+    <body-content>empty</body-content>
+    <attribute>
+      <name>echo</name>
+      <required>yes</required>
+      <rtexprvalue>true</rtexprvalue>
+    </attribute>
+  </tag>
+
+</taglib>
\ No newline at end of file
diff --git a/test/webapp-2.4/WEB-INF/web.xml b/test/webapp-2.4/WEB-INF/web.xml
new file mode 100644 (file)
index 0000000..1ac8b27
--- /dev/null
@@ -0,0 +1,33 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+-->
+<web-app xmlns="http://java.sun.com/xml/ns/javaee"
+  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+  xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
+                      http://java.sun.com/xml/ns/javaee/web-app_2_4.xsd"
+  version="2.4">
+  <display-name>Tomcat Servlet 2.4 Tests</display-name>
+  <description>
+    Provides a web application used by the Tomcat unit tests to ensure that
+    Tomcat meets the requirements of the current JSP and Servlet specification
+    for web applications that declare that they follow version 2.4 of the
+    Servlet specification and version 2.0 of the JSP specification. This
+    typically means ensuring that features introduced in later versions of the
+    specification do not change the behaviour of applications that declared an
+    earlier version of the specification. 
+  </description>
+</web-app>
\ No newline at end of file
diff --git a/test/webapp-2.4/el-as-literal.jsp b/test/webapp-2.4/el-as-literal.jsp
new file mode 100644 (file)
index 0000000..9b47cc0
--- /dev/null
@@ -0,0 +1,22 @@
+<%--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+--%>
+<html>
+  <body>
+    <p>00-${'hello world'}</p>
+    <p>01-#{'hello world'}</p>
+  </body>
+</html>
\ No newline at end of file
diff --git a/test/webapp-2.4/tld-versions.jsp b/test/webapp-2.4/tld-versions.jsp
new file mode 100644 (file)
index 0000000..debf250
--- /dev/null
@@ -0,0 +1,29 @@
+<%--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+--%>
+<html><body>
+<%@ taglib prefix="tags11" uri="http://tomcat.apache.org/tags11" %>
+<%@ taglib prefix="tags12" uri="http://tomcat.apache.org/tags12" %>
+<%@ taglib prefix="tags20" uri="http://tomcat.apache.org/tags20" %>
+<%@ taglib prefix="tags21" uri="http://tomcat.apache.org/tags21" %>
+<tags11:Echo echo="${'00-hello world'}"/>
+<tags11:Echo echo="#{'01-hello world'}"/>
+<tags12:Echo echo="${'02-hello world'}"/>
+<tags12:Echo echo="#{'03-hello world'}"/>
+<tags20:Echo echo="${'04-hello world'}"/>
+<tags20:Echo echo="#{'05-hello world'}"/>
+<tags21:Echo echo="${'06-hello world'}"/>
+</body></html>
\ No newline at end of file
diff --git a/test/webapp-2.5/WEB-INF/tags11.tld b/test/webapp-2.5/WEB-INF/tags11.tld
new file mode 100644 (file)
index 0000000..b78be03
--- /dev/null
@@ -0,0 +1,36 @@
+<?xml version="1.0" encoding="ISO-8859-1" ?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+--><!DOCTYPE taglib
+      PUBLIC "-//Sun Microsystems, Inc.//DTD JSP Tag Library 1.1//EN"
+      "http://java.sun.com/dtd/web-jsptaglibrary_1_1.dtd">
+<taglib>
+  <tlibversion>1.0</tlibversion>
+  <jspversion>1.1</jspversion>
+  <shortname>Tags11</shortname>
+  <uri>http://tomcat.apache.org/tags11</uri>
+
+  <tag>
+    <name>Echo</name>
+    <tagclass>org.apache.jasper.compiler.TestValidator$Echo</tagclass>
+    <bodycontent>empty</bodycontent>
+    <attribute>
+      <name>echo</name>
+      <required>yes</required>
+    </attribute>
+  </tag>
+
+</taglib>
\ No newline at end of file
diff --git a/test/webapp-2.5/WEB-INF/tags12.tld b/test/webapp-2.5/WEB-INF/tags12.tld
new file mode 100644 (file)
index 0000000..55908d9
--- /dev/null
@@ -0,0 +1,36 @@
+<?xml version="1.0" encoding="ISO-8859-1" ?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+--><!DOCTYPE taglib
+      PUBLIC "-//Sun Microsystems, Inc.//DTD JSP Tag Library 1.2//EN"
+      "http://java.sun.com/dtd/web-jsptaglibrary_1_2.dtd">
+<taglib>
+  <tlib-version>1.0</tlib-version>
+  <jsp-version>1.2</jsp-version>
+  <short-name>Tags12</short-name>
+  <uri>http://tomcat.apache.org/tags12</uri>
+
+  <tag>
+    <name>Echo</name>
+    <tagclass>org.apache.jasper.compiler.TestValidator$Echo</tagclass>
+    <body-content>empty</body-content>
+    <attribute>
+      <name>echo</name>
+      <required>yes</required>
+    </attribute>
+  </tag>
+
+</taglib>
\ No newline at end of file
diff --git a/test/webapp-2.5/WEB-INF/tags20.tld b/test/webapp-2.5/WEB-INF/tags20.tld
new file mode 100644 (file)
index 0000000..9130867
--- /dev/null
@@ -0,0 +1,37 @@
+<?xml version="1.0" encoding="ISO-8859-1" ?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+--><taglib xmlns="http://java.sun.com/xml/ns/javaee"
+      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+      xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
+      http://java.sun.com/xml/ns/javaee/web-jsptaglibrary_2_0.xsd"
+      version="2.0">
+  <tlib-version>1.0</tlib-version>
+  <short-name>Tags20</short-name>
+  <uri>http://tomcat.apache.org/tags20</uri>
+
+  <tag>
+    <name>Echo</name>
+    <tagclass>org.apache.jasper.compiler.TestValidator$Echo</tagclass>
+    <body-content>empty</body-content>
+    <attribute>
+      <name>echo</name>
+      <required>yes</required>
+      <rtexprvalue>true</rtexprvalue>
+    </attribute>
+  </tag>
+
+</taglib>
\ No newline at end of file
diff --git a/test/webapp-2.5/WEB-INF/tags21.tld b/test/webapp-2.5/WEB-INF/tags21.tld
new file mode 100644 (file)
index 0000000..7b8c3c5
--- /dev/null
@@ -0,0 +1,37 @@
+<?xml version="1.0" encoding="ISO-8859-1" ?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+--><taglib xmlns="http://java.sun.com/xml/ns/javaee"
+      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+      xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
+      http://java.sun.com/xml/ns/javaee/web-jsptaglibrary_2_1.xsd"
+      version="2.1">
+  <tlib-version>1.0</tlib-version>
+  <short-name>Tags21</short-name>
+  <uri>http://tomcat.apache.org/tags21</uri>
+
+  <tag>
+    <name>Echo</name>
+    <tagclass>org.apache.jasper.compiler.TestValidator$Echo</tagclass>
+    <body-content>empty</body-content>
+    <attribute>
+      <name>echo</name>
+      <required>yes</required>
+      <rtexprvalue>true</rtexprvalue>
+    </attribute>
+  </tag>
+
+</taglib>
\ No newline at end of file
diff --git a/test/webapp-2.5/WEB-INF/web.xml b/test/webapp-2.5/WEB-INF/web.xml
new file mode 100644 (file)
index 0000000..383287d
--- /dev/null
@@ -0,0 +1,33 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+-->
+<web-app xmlns="http://java.sun.com/xml/ns/javaee"
+  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+  xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
+                      http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
+  version="2.5">
+  <display-name>Tomcat Servlet 2.5 Tests</display-name>
+  <description>
+    Provides a web application used by the Tomcat unit tests to ensure that
+    Tomcat meets the requirements of the current JSP and Servlet specification
+    for web applications that declare that they follow version 2.5 of the
+    Servlet specification and version 2.1 of the JSP specification. This
+    typically means ensuring that features introduced in later versions of the
+    specification do not change the behaviour of applications that declared an
+    earlier version of the specification. 
+  </description>
+</web-app>
\ No newline at end of file
diff --git a/test/webapp-2.5/el-as-literal.jsp b/test/webapp-2.5/el-as-literal.jsp
new file mode 100644 (file)
index 0000000..f48e114
--- /dev/null
@@ -0,0 +1,21 @@
+<%--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+--%>
+<html>
+  <body>
+    <p>00-${'hello world'}</p>
+  </body>
+</html>
\ No newline at end of file
diff --git a/test/webapp-2.5/tld-versions.jsp b/test/webapp-2.5/tld-versions.jsp
new file mode 100644 (file)
index 0000000..debf250
--- /dev/null
@@ -0,0 +1,29 @@
+<%--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+--%>
+<html><body>
+<%@ taglib prefix="tags11" uri="http://tomcat.apache.org/tags11" %>
+<%@ taglib prefix="tags12" uri="http://tomcat.apache.org/tags12" %>
+<%@ taglib prefix="tags20" uri="http://tomcat.apache.org/tags20" %>
+<%@ taglib prefix="tags21" uri="http://tomcat.apache.org/tags21" %>
+<tags11:Echo echo="${'00-hello world'}"/>
+<tags11:Echo echo="#{'01-hello world'}"/>
+<tags12:Echo echo="${'02-hello world'}"/>
+<tags12:Echo echo="#{'03-hello world'}"/>
+<tags20:Echo echo="${'04-hello world'}"/>
+<tags20:Echo echo="#{'05-hello world'}"/>
+<tags21:Echo echo="${'06-hello world'}"/>
+</body></html>
\ No newline at end of file
diff --git a/test/webapp-3.0/el-as-literal.jsp b/test/webapp-3.0/el-as-literal.jsp
new file mode 100644 (file)
index 0000000..f48e114
--- /dev/null
@@ -0,0 +1,21 @@
+<%--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+--%>
+<html>
+  <body>
+    <p>00-${'hello world'}</p>
+  </body>
+</html>
\ No newline at end of file