Fix building with QT_NO_BEARERMANAGEMENT
Some of the examples make no sense without bearer management and QNetworkSession is not defined if QT_NO_BEARERMANAGEMENT, so tst_qnetworkreply.cpp has to be adjusted. Change-Id: Ic2f73746cba74f670ae5b5e99b0be1461ff6d182 Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
This commit is contained in:
parent
81c2ca7f22
commit
6c72a4a95b
@ -11,19 +11,25 @@ qtHaveModule(widgets) {
|
||||
blockingfortuneclient \
|
||||
broadcastreceiver \
|
||||
broadcastsender \
|
||||
fortuneclient \
|
||||
fortuneserver \
|
||||
http \
|
||||
loopback \
|
||||
threadedfortuneserver \
|
||||
googlesuggest \
|
||||
torrent \
|
||||
bearermonitor \
|
||||
multicastreceiver \
|
||||
multicastsender
|
||||
|
||||
# no QProcess
|
||||
!vxworks:!qnx:!winrt:SUBDIRS += network-chat
|
||||
load(qfeatures)
|
||||
!contains(QT_DISABLED_FEATURES, bearermanagement) {
|
||||
# no QProcess
|
||||
!vxworks:!qnx:!winrt:SUBDIRS += network-chat
|
||||
|
||||
SUBDIRS += \
|
||||
bearermonitor \
|
||||
fortuneclient \
|
||||
fortuneserver
|
||||
|
||||
}
|
||||
|
||||
contains(QT_CONFIG, openssl):SUBDIRS += securesocketclient
|
||||
contains(QT_CONFIG, openssl-linked):SUBDIRS += securesocketclient
|
||||
|
@ -7738,6 +7738,7 @@ void tst_QNetworkReply::emitErrorForAllReplies() // QTBUG-36890
|
||||
#ifdef QT_BUILD_INTERNAL
|
||||
void tst_QNetworkReply::backgroundRequest_data()
|
||||
{
|
||||
#ifndef QT_NO_BEARERMANAGEMENT
|
||||
QTest::addColumn<QUrl>("url");
|
||||
QTest::addColumn<bool>("background");
|
||||
QTest::addColumn<int>("policy");
|
||||
@ -7763,7 +7764,7 @@ void tst_QNetworkReply::backgroundRequest_data()
|
||||
QTest::newRow("ftp, bg, normal") << ftpurl << true << (int)QNetworkSession::NoPolicy << QNetworkReply::NoError;
|
||||
QTest::newRow("ftp, fg, nobg") << ftpurl << false << (int)QNetworkSession::NoBackgroundTrafficPolicy << QNetworkReply::NoError;
|
||||
QTest::newRow("ftp, bg, nobg") << ftpurl << true << (int)QNetworkSession::NoBackgroundTrafficPolicy << QNetworkReply::BackgroundRequestNotAllowedError;
|
||||
|
||||
#endif // !QT_NO_BEARERMANAGEMENT
|
||||
}
|
||||
#endif
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user