mirror of
https://github.com/pocoproject/poco.git
synced 2025-05-03 07:52:29 +02:00
Remove try/catch. Exception is avoided by CPPUNI_IGNORE
Signed-off-by: FrancisANDRE <zosrothko@orange.fr>
This commit is contained in:
parent
609072a5ad
commit
6d96fb30ec
@ -307,7 +307,6 @@ void HTTPSClientSessionTest::testInterop()
|
|||||||
|
|
||||||
void HTTPSClientSessionTest::testProxy()
|
void HTTPSClientSessionTest::testProxy()
|
||||||
{
|
{
|
||||||
try {
|
|
||||||
HTTPSTestServer srv;
|
HTTPSTestServer srv;
|
||||||
HTTPSClientSession s("secure.appinf.com");
|
HTTPSClientSession s("secure.appinf.com");
|
||||||
s.setProxy(
|
s.setProxy(
|
||||||
@ -324,10 +323,6 @@ void HTTPSClientSessionTest::testProxy()
|
|||||||
std::string str(ostr.str());
|
std::string str(ostr.str());
|
||||||
assert(str == "This is a test file for NetSSL.\n");
|
assert(str == "This is a test file for NetSSL.\n");
|
||||||
assert(cert.commonName() == "secure.appinf.com" || cert.commonName() == "*.appinf.com");
|
assert(cert.commonName() == "secure.appinf.com" || cert.commonName() == "*.appinf.com");
|
||||||
}
|
|
||||||
catch (Poco::Net::HTTPException e) {
|
|
||||||
std::cout << e.displayText() << std::endl;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -480,7 +475,7 @@ CppUnit::Test* HTTPSClientSessionTest::suite()
|
|||||||
CppUnit_addTest(pSuite, HTTPSClientSessionTest, testKeepAlive);
|
CppUnit_addTest(pSuite, HTTPSClientSessionTest, testKeepAlive);
|
||||||
CppUnit_addTest(pSuite, HTTPSClientSessionTest, testInterop);
|
CppUnit_addTest(pSuite, HTTPSClientSessionTest, testInterop);
|
||||||
#ifdef FIXME
|
#ifdef FIXME
|
||||||
should use a public proxy server
|
testProxy should use a public proxy server
|
||||||
http://www.publicproxyservers.com/proxy/list1.html
|
http://www.publicproxyservers.com/proxy/list1.html
|
||||||
Really working public proxy servers - page 1 of 6.
|
Really working public proxy servers - page 1 of 6.
|
||||||
#endif
|
#endif
|
||||||
|
@ -85,7 +85,6 @@ void HTTPSStreamFactoryTest::testRedirect()
|
|||||||
|
|
||||||
void HTTPSStreamFactoryTest::testProxy()
|
void HTTPSStreamFactoryTest::testProxy()
|
||||||
{
|
{
|
||||||
try {
|
|
||||||
HTTPSTestServer server;
|
HTTPSTestServer server;
|
||||||
HTTPSStreamFactory factory(
|
HTTPSStreamFactory factory(
|
||||||
Application::instance().config().getString("testsuite.proxy.host"),
|
Application::instance().config().getString("testsuite.proxy.host"),
|
||||||
@ -96,10 +95,7 @@ void HTTPSStreamFactoryTest::testProxy()
|
|||||||
std::ostringstream ostr;
|
std::ostringstream ostr;
|
||||||
StreamCopier::copyStream(*pStr.get(), ostr);
|
StreamCopier::copyStream(*pStr.get(), ostr);
|
||||||
assert(ostr.str().length() > 0);
|
assert(ostr.str().length() > 0);
|
||||||
}
|
|
||||||
catch (Poco::Net::HTTPException e) {
|
|
||||||
std::cout << e.displayText() << std::endl;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -139,7 +135,7 @@ CppUnit::Test* HTTPSStreamFactoryTest::suite()
|
|||||||
CppUnit_addTest(pSuite, HTTPSStreamFactoryTest, testEmptyPath);
|
CppUnit_addTest(pSuite, HTTPSStreamFactoryTest, testEmptyPath);
|
||||||
CppUnit_addTest(pSuite, HTTPSStreamFactoryTest, testRedirect);
|
CppUnit_addTest(pSuite, HTTPSStreamFactoryTest, testRedirect);
|
||||||
#ifdef FIXME
|
#ifdef FIXME
|
||||||
should use a public proxy server
|
testProxy should use a public proxy server
|
||||||
http://www.publicproxyservers.com/proxy/list1.html
|
http://www.publicproxyservers.com/proxy/list1.html
|
||||||
Really working public proxy servers - page 1 of 6.
|
Really working public proxy servers - page 1 of 6.
|
||||||
#endif
|
#endif
|
||||||
|
@ -314,7 +314,11 @@ void HTTPSClientSessionTest::testInterop()
|
|||||||
|
|
||||||
void HTTPSClientSessionTest::testProxy()
|
void HTTPSClientSessionTest::testProxy()
|
||||||
{
|
{
|
||||||
try {
|
#ifdef FIXME
|
||||||
|
testProxy should use a public proxy server
|
||||||
|
http://www.publicproxyservers.com/proxy/list1.html
|
||||||
|
Really working public proxy servers - page 1 of 6.
|
||||||
|
#endif
|
||||||
HTTPSTestServer srv;
|
HTTPSTestServer srv;
|
||||||
HTTPSClientSession s("secure.appinf.com");
|
HTTPSClientSession s("secure.appinf.com");
|
||||||
s.setProxy(
|
s.setProxy(
|
||||||
@ -331,10 +335,6 @@ void HTTPSClientSessionTest::testProxy()
|
|||||||
std::string str(ostr.str());
|
std::string str(ostr.str());
|
||||||
assert(str == "This is a test file for NetSSL.\n");
|
assert(str == "This is a test file for NetSSL.\n");
|
||||||
assert(cert.commonName() == "secure.appinf.com" || cert.commonName() == "*.appinf.com");
|
assert(cert.commonName() == "secure.appinf.com" || cert.commonName() == "*.appinf.com");
|
||||||
}
|
|
||||||
catch (Poco::Exception e) {
|
|
||||||
std::cout << e.displayText() << std::endl;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -85,7 +85,11 @@ void HTTPSStreamFactoryTest::testRedirect()
|
|||||||
|
|
||||||
void HTTPSStreamFactoryTest::testProxy()
|
void HTTPSStreamFactoryTest::testProxy()
|
||||||
{
|
{
|
||||||
try {
|
#ifdef FIXME
|
||||||
|
testProxy should use a public proxy server
|
||||||
|
http://www.publicproxyservers.com/proxy/list1.html
|
||||||
|
Really working public proxy servers - page 1 of 6.
|
||||||
|
#endif
|
||||||
HTTPSTestServer server;
|
HTTPSTestServer server;
|
||||||
HTTPSStreamFactory factory(
|
HTTPSStreamFactory factory(
|
||||||
Application::instance().config().getString("testsuite.proxy.host"),
|
Application::instance().config().getString("testsuite.proxy.host"),
|
||||||
@ -96,10 +100,6 @@ void HTTPSStreamFactoryTest::testProxy()
|
|||||||
std::ostringstream ostr;
|
std::ostringstream ostr;
|
||||||
StreamCopier::copyStream(*pStr.get(), ostr);
|
StreamCopier::copyStream(*pStr.get(), ostr);
|
||||||
assert(ostr.str().length() > 0);
|
assert(ostr.str().length() > 0);
|
||||||
}
|
|
||||||
catch (Poco::Exception e) {
|
|
||||||
std::cout << e.displayText() << std::endl;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user