This is an automated email from the ASF dual-hosted git repository. markt pushed a commit to branch main in repository https://gitbox.apache.org/repos/asf/tomcat.git
commit e6304ca9f0e08730efb630b498d975545d7ab754 Author: Mark Thomas <ma...@apache.org> AuthorDate: Wed Sep 22 19:53:35 2021 +0100 Fix test failures --- test/jakarta/servlet/resources/TestSchemaValidation.java | 2 +- test/org/apache/jasper/servlet/TestJspCServletContext.java | 4 ++-- test/org/apache/tomcat/util/descriptor/web/TestWebXml.java | 7 ++++++- 3 files changed, 9 insertions(+), 4 deletions(-) diff --git a/test/jakarta/servlet/resources/TestSchemaValidation.java b/test/jakarta/servlet/resources/TestSchemaValidation.java index 223e5be..dd070fb 100644 --- a/test/jakarta/servlet/resources/TestSchemaValidation.java +++ b/test/jakarta/servlet/resources/TestSchemaValidation.java @@ -39,7 +39,7 @@ public class TestSchemaValidation { digester.push(new WebXml()); WebXml desc = (WebXml) digester.parse( new File("test/webapp/WEB-INF/web.xml")); - Assert.assertEquals("5.0", desc.getVersion()); + Assert.assertEquals("6.0", desc.getVersion()); Assert.assertEquals(0, handler.getErrors().size()); Assert.assertEquals(0, handler.getWarnings().size()); } diff --git a/test/org/apache/jasper/servlet/TestJspCServletContext.java b/test/org/apache/jasper/servlet/TestJspCServletContext.java index 57cd4e9..f8d0adb 100644 --- a/test/org/apache/jasper/servlet/TestJspCServletContext.java +++ b/test/org/apache/jasper/servlet/TestJspCServletContext.java @@ -34,7 +34,7 @@ public class TestJspCServletContext { File appDir = new File("test/webapp"); JspCServletContext context = new JspCServletContext( null, appDir.toURI().toURL(), null, false, false); - Assert.assertEquals(5, context.getEffectiveMajorVersion()); + Assert.assertEquals(6, context.getEffectiveMajorVersion()); Assert.assertEquals(0, context.getEffectiveMinorVersion()); JspConfigDescriptor jspConfigDescriptor = context.getJspConfigDescriptor(); @@ -148,7 +148,7 @@ public class TestJspCServletContext { File appDir = new File("test/webresources/dir1"); JspCServletContext context = new JspCServletContext( null, appDir.toURI().toURL(), null, false, false); - Assert.assertEquals(5, context.getEffectiveMajorVersion()); + Assert.assertEquals(6, context.getEffectiveMajorVersion()); Assert.assertEquals(0, context.getEffectiveMinorVersion()); } diff --git a/test/org/apache/tomcat/util/descriptor/web/TestWebXml.java b/test/org/apache/tomcat/util/descriptor/web/TestWebXml.java index 898cec6..a2c79e2 100644 --- a/test/org/apache/tomcat/util/descriptor/web/TestWebXml.java +++ b/test/org/apache/tomcat/util/descriptor/web/TestWebXml.java @@ -46,7 +46,7 @@ public class TestWebXml { WebXml webxml = new WebXml(); // Defaults - Assert.assertEquals(5, webxml.getMajorVersion()); + Assert.assertEquals(6, webxml.getMajorVersion()); Assert.assertEquals(0, webxml.getMinorVersion()); // Both get changed @@ -182,6 +182,11 @@ public class TestWebXml { doTestValidateVersion("5.0"); } + @Test + public void testValidateVersion60() throws IOException, SAXException { + doTestValidateVersion("6.0"); + } + private void doTestValidateVersion(String version) throws IOException, SAXException { WebXml webxml = new WebXml(); --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org