Closed GoogleCodeExporter closed 8 years ago
Thanks for the test case
Original comment by johan.ha...@gmail.com
on 29 May 2012 at 3:30
It's fixed in trunk now. Thanks for reporting. I've created an automatic test
against your service so I hope that it doesn't go down :)
Original comment by johan.ha...@gmail.com
on 29 May 2012 at 4:51
Sad I was on holiday for 3 weeks. I might have been been able to post this
before 1.6.2 :
The fix falls short. It does not recognize escaped sequences in path segments.
See below modified test case.
public class DummyTest {
private static final String APACHE_404 = "http://www.apache.org/question-%3F";
private String search() {
String html = RestAssured.given()
.expect()
.statusCode(404)
.contentType(ContentType.HTML)
.get(APACHE_404)
.asString();
// find search term in search input element
Pattern p = Pattern.compile("/question-(.+?) ");
Matcher m = p.matcher(html);
Assert.assertTrue(m.find());
String echo = m.group(1);
return echo;
}
@Test
public void testUrlEncoding() {
Assert.assertEquals("%3F", search());
RestAssured.urlEncodingEnabled = false;
Assert.assertEquals("?", search());
}
}
Original comment by mi.koel...@googlemail.com
on 18 Jun 2012 at 11:28
Thanks for the test case thought I cannot reproduce it with the latest master
(sha 8a3fc06)
Original comment by johan.ha...@gmail.com
on 14 Nov 2013 at 9:58
Original issue reported on code.google.com by
mi.koel...@googlemail.com
on 24 May 2012 at 2:35