Author: markt
Date: Mon Sep 19 20:29:04 2016
New Revision: 1761500

URL: http://svn.apache.org/viewvc?rev=1761500&view=rev
Log:
Fix RewriteValve test failures.

Modified:
    tomcat/trunk/build.xml
    tomcat/trunk/test/org/apache/catalina/valves/rewrite/TestRewriteValve.java

Modified: tomcat/trunk/build.xml
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/build.xml?rev=1761500&r1=1761499&r2=1761500&view=diff
==============================================================================
--- tomcat/trunk/build.xml (original)
+++ tomcat/trunk/build.xml Mon Sep 19 20:29:04 2016
@@ -1414,6 +1414,7 @@
         threads="${test.threads}" >
 
         <jvmarg value="${test.jvmarg.egd}"/>
+        <jvmarg value="-Dfile.encoding=UTF-8"/>
         <jvmarg value="-Djava.library.path=${test.apr.loc}"/>
         <jvmarg value="${test.formatter}"/>
         <jvmarg 
value="-Djava.net.preferIPv4Stack=${java.net.preferIPv4Stack}"/>

Modified: 
tomcat/trunk/test/org/apache/catalina/valves/rewrite/TestRewriteValve.java
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/test/org/apache/catalina/valves/rewrite/TestRewriteValve.java?rev=1761500&r1=1761499&r2=1761500&view=diff
==============================================================================
--- tomcat/trunk/test/org/apache/catalina/valves/rewrite/TestRewriteValve.java 
(original)
+++ tomcat/trunk/test/org/apache/catalina/valves/rewrite/TestRewriteValve.java 
Mon Sep 19 20:29:04 2016
@@ -27,6 +27,15 @@ import org.apache.catalina.startup.Tomca
 import org.apache.catalina.startup.TomcatBaseTest;
 import org.apache.tomcat.util.buf.ByteChunk;
 
+/*
+ * Implementation note:
+ *
+ * A number of these tests involve the rewrite valve returning a HTTP Location
+ * header that include un-encoded UTF-8 bytes. How the HTTP client handles 
these
+ * depends on the default character encoding configured for the JVM running the
+ * test. The tests expect the client to be configured with UTF-8 as the default
+ * encoding. Use of any other encoding is likely to lead to test failures.
+ */
 public class TestRewriteValve extends TomcatBaseTest {
 
     @Test



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

Reply via email to