test: Don't fail if the network test server is not set up
Not having access to a network test server is not a failure per se but rather an enviromental condition not met at run-time. Change-Id: Ie7d10ca5fbf2df45fb1fd1ac19718c9fae855c03 Reviewed-by: Caroline Chao <caroline.chao@digia.com>bb10
parent
ed19c0875e
commit
704a4e4747
|
|
@ -138,7 +138,8 @@ Q_DECLARE_METATYPE(QNetworkRequest::CacheLoadControl)
|
|||
|
||||
void tst_QAbstractNetworkCache::initTestCase()
|
||||
{
|
||||
QVERIFY(QtNetworkSettings::verifyTestNetworkSettings());
|
||||
if (!QtNetworkSettings::verifyTestNetworkSettings())
|
||||
QSKIP("No network test server available");
|
||||
#ifndef QT_NO_BEARERMANAGEMENT
|
||||
netConfMan = new QNetworkConfigurationManager(this);
|
||||
networkConfiguration = netConfMan->defaultConfiguration();
|
||||
|
|
|
|||
|
|
@ -87,7 +87,8 @@ tst_QNetworkInterface::~tst_QNetworkInterface()
|
|||
|
||||
void tst_QNetworkInterface::initTestCase()
|
||||
{
|
||||
QVERIFY(QtNetworkSettings::verifyTestNetworkSettings());
|
||||
if (!QtNetworkSettings::verifyTestNetworkSettings())
|
||||
QSKIP("No network test server available");
|
||||
#ifndef QT_NO_BEARERMANAGEMENT
|
||||
netConfMan = new QNetworkConfigurationManager(this);
|
||||
networkConfiguration = netConfMan->defaultConfiguration();
|
||||
|
|
|
|||
|
|
@ -167,7 +167,8 @@ void tst_QTcpServer::initTestCase_data()
|
|||
|
||||
void tst_QTcpServer::initTestCase()
|
||||
{
|
||||
QVERIFY(QtNetworkSettings::verifyTestNetworkSettings());
|
||||
if (!QtNetworkSettings::verifyTestNetworkSettings())
|
||||
QSKIP("No network test server available");
|
||||
#ifndef QT_NO_BEARERMANAGEMENT
|
||||
QNetworkConfigurationManager man;
|
||||
networkSession = new QNetworkSession(man.defaultConfiguration(), this);
|
||||
|
|
|
|||
|
|
@ -166,7 +166,8 @@ void tst_QUdpSocket::initTestCase_data()
|
|||
|
||||
void tst_QUdpSocket::initTestCase()
|
||||
{
|
||||
QVERIFY(QtNetworkSettings::verifyTestNetworkSettings());
|
||||
if (!QtNetworkSettings::verifyTestNetworkSettings())
|
||||
QSKIP("No network test server available");
|
||||
}
|
||||
|
||||
void tst_QUdpSocket::init()
|
||||
|
|
|
|||
|
|
@ -362,7 +362,8 @@ QHostAddress tst_NetworkSelfTest::serverIpAddress()
|
|||
|
||||
void tst_NetworkSelfTest::initTestCase()
|
||||
{
|
||||
QVERIFY(QtNetworkSettings::verifyTestNetworkSettings());
|
||||
if (!QtNetworkSettings::verifyTestNetworkSettings())
|
||||
QSKIP("No network test server available");
|
||||
#ifndef QT_NO_BEARERMANAGEMENT
|
||||
netConfMan = new QNetworkConfigurationManager(this);
|
||||
networkConfiguration = netConfMan->defaultConfiguration();
|
||||
|
|
|
|||
|
|
@ -128,7 +128,8 @@ tst_QNetworkAccessManager_And_QProgressDialog::tst_QNetworkAccessManager_And_QPr
|
|||
|
||||
void tst_QNetworkAccessManager_And_QProgressDialog::initTestCase()
|
||||
{
|
||||
QVERIFY(QtNetworkSettings::verifyTestNetworkSettings());
|
||||
if (!QtNetworkSettings::verifyTestNetworkSettings())
|
||||
QSKIP("No network test server available");
|
||||
}
|
||||
|
||||
void tst_QNetworkAccessManager_And_QProgressDialog::downloadCheck_data()
|
||||
|
|
|
|||
Loading…
Reference in New Issue