[Bug 57530] Reimplement TestAbstractHttp11Processor.testNon2xxResponseWithExpectation test using SimpleHttpClient instead of Java 6
https://bz.apache.org/bugzilla/show_bug.cgi?id=57530 Violeta Georgieva violet...@apache.org changed: What|Removed |Added Resolution|--- |FIXED Status|NEW |RESOLVED --- Comment #7 from Violeta Georgieva violet...@apache.org --- Fix is available in Tomcat 7 trunk -- You are receiving this mail because: You are the assignee for the bug. - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
[Bug 57530] Reimplement TestAbstractHttp11Processor.testNon2xxResponseWithExpectation test using SimpleHttpClient instead of Java 6
https://bz.apache.org/bugzilla/show_bug.cgi?id=57530 --- Comment #6 from Violeta Georgieva violet...@apache.org --- I'm going to reimplement the TestAbstractHttp11Processor.testNon2xxResponseWithExpectation with SimpleHttpClient. Regards, Violeta -- You are receiving this mail because: You are the assignee for the bug. - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
[Bug 57530] Reimplement TestAbstractHttp11Processor.testNon2xxResponseWithExpectation test using SimpleHttpClient instead of Java 6
https://bz.apache.org/bugzilla/show_bug.cgi?id=57530 --- Comment #5 from Christopher Schultz ch...@christopherschultz.net --- Having played-around with sun.net.http.allowRestrictedHeaders, I believe it's one of those things that gets consulted one time and then never looked-at again. That means that, if the tests are run in an unpredictable order, you'll never know which tests are using that value and which aren't. And you can't turn it off. For predictability's sake, maybe we should set that system property for the whole set of unit tests to be run? I think in the long run, use of SimpleHttpClient is probably better, since it will handle Expect the way we ... expect. -- You are receiving this mail because: You are the assignee for the bug. - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
[Bug 57530] Reimplement TestAbstractHttp11Processor.testNon2xxResponseWithExpectation test using SimpleHttpClient instead of Java 6
https://bz.apache.org/bugzilla/show_bug.cgi?id=57530 --- Comment #4 from Konstantin Kolinko knst.koli...@gmail.com --- (In reply to Violeta Georgieva from comment #3) Interesting. This fix looks like having a too wide scope for a single failing test, but I am OK with it. Setting the system property affects all the tests in the test class (as they are run in random order in the same JVM), so setting it in a @Before method looks fair. I do not expect any negative consequences from that property. (In reply to Konstantin Kolinko from comment #0) I think that this case can be reimplemented using a more simple client implementation, org.apache.catalina.startup.SimpleHttpClient TestFormAuthenticator has an example of using a SimpleHttpClient to test behaviour of Expect/Continue handling -- You are receiving this mail because: You are the assignee for the bug. - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
[Bug 57530] Reimplement TestAbstractHttp11Processor.testNon2xxResponseWithExpectation test using SimpleHttpClient instead of Java 6
https://bz.apache.org/bugzilla/show_bug.cgi?id=57530 --- Comment #3 from Violeta Georgieva violet...@apache.org --- Hi, What do you think if we add the code below. Currently Expect header is restricted and because of this it is not added as request property. If we set sun.net.http.allowRestrictedHeaders to true then it is added and the test passes. Regards, Violeta Index: TestAbstractHttp11Processor.java === --- TestAbstractHttp11Processor.java(revision 1684193) +++ TestAbstractHttp11Processor.java(working copy) @@ -42,6 +42,7 @@ import static org.junit.Assert.assertTrue; import org.junit.Assert; +import org.junit.Before; import org.junit.Test; import org.apache.catalina.Context; @@ -57,6 +58,13 @@ public class TestAbstractHttp11Processor extends TomcatBaseTest { +@Before +@Override +public void setUp() throws Exception { +super.setUp(); +System.setProperty(sun.net.http.allowRestrictedHeaders, true); +} + @Test public void testResponseWithErrorChunked() throws Exception { Tomcat tomcat = getTomcatInstance(); -- You are receiving this mail because: You are the assignee for the bug. - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
[Bug 57530] Reimplement TestAbstractHttp11Processor.testNon2xxResponseWithExpectation test using SimpleHttpClient instead of Java 6
https://bz.apache.org/bugzilla/show_bug.cgi?id=57530 --- Comment #2 from Christopher Schultz ch...@christopherschultz.net --- It looks like the test code is missing a call to HttpURLConnection.setFixedLengthStreamingMode() or HttpURLConnection.setChunkedStreamingMode(), which would have (?) made this work with older versions of the JRE. -- You are receiving this mail because: You are the assignee for the bug. - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
[Bug 57530] Reimplement TestAbstractHttp11Processor.testNon2xxResponseWithExpectation test using SimpleHttpClient instead of Java 6
https://bz.apache.org/bugzilla/show_bug.cgi?id=57530 Rainer Jung rainer.j...@kippdata.de changed: What|Removed |Added OS||All --- Comment #1 from Rainer Jung rainer.j...@kippdata.de --- http://bugs.java.com/view_bug.do?bug_id=8012625 JDK-8012625 : Incorrect handling of HTTP/1.1 Expect: 100-continue in HttpURLConnection That one is said to be fixed by today's release of 1.7.0_80: http://www.oracle.com/technetwork/java/javase/2col/7u80-bugfixes-2494167.html Regards, Rainer -- You are receiving this mail because: You are the assignee for the bug. - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org