diff options
| author | Tatsuhiro Tsujikawa <tatsuhiro.t@gmail.com> | 2008-11-18 15:10:47 +0000 |
|---|---|---|
| committer | Tatsuhiro Tsujikawa <tatsuhiro.t@gmail.com> | 2008-11-18 15:10:47 +0000 |
| commit | 931bd985db636625a9db0872001f432e8e212865 (patch) | |
| tree | 6b7b7586ac87fb5ae01fb2da5dc34c67605ed5ac /test/RequestTest.cc | |
| parent | 53b418cde9b3fa4779c1b8bfb4b54aafa74a22e1 (diff) | |
2008-11-19 Tatsuhiro Tsujikawa <t-tujikawa@users.sourceforge.net>
Do not urlencode Request::url in setUrl() because we want
unmodified URL using Request::getUrl()
* src/Request.cc
* src/Request.h
* test/RequestTest.cc
Diffstat (limited to 'test/RequestTest.cc')
| -rw-r--r-- | test/RequestTest.cc | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/test/RequestTest.cc b/test/RequestTest.cc index 20ef893b..8774e895 100644 --- a/test/RequestTest.cc +++ b/test/RequestTest.cc @@ -274,7 +274,9 @@ void RequestTest::testSetUrl17() CPPUNIT_ASSERT_EQUAL(std::string("http://host:80/file%3cwith%252%20%20space" "/file%20with%20space;param%25?a=/?"), req.getCurrentUrl()); - CPPUNIT_ASSERT_EQUAL(req.getCurrentUrl(), req.getUrl()); + CPPUNIT_ASSERT_EQUAL(std::string("http://host:80/file<with%2 %20space" + "/file with space;param%?a=/?"), + req.getUrl()); } void RequestTest::testRedirectUrl() { @@ -365,7 +367,8 @@ void RequestTest::testInnerLink() { Request req; bool v = req.setUrl("http://aria.rednoah.com/index.html#download"); CPPUNIT_ASSERT(v); - CPPUNIT_ASSERT_EQUAL(std::string("http://aria.rednoah.com/index.html"), + CPPUNIT_ASSERT_EQUAL(std::string("http://aria.rednoah.com/index.html" + "#download"), req.getUrl()); CPPUNIT_ASSERT_EQUAL(std::string("http://aria.rednoah.com/index.html"), req.getCurrentUrl()); |
