diff --git a/tests/auto/productapitest.cpp b/tests/auto/productapitest.cpp index a466868164337b7c5dbde6b7dbe6a28e51c4621e..dd0fa0f637316c40ad65124b6b9c936c49877072 100644 --- a/tests/auto/productapitest.cpp +++ b/tests/auto/productapitest.cpp @@ -100,7 +100,7 @@ private slots: reply = RESTApi::listProducts(&client); QVERIFY(waitForFinished(reply)); QCOMPARE(reply->error(), QNetworkReply::NoError); - QCOMPARE(reply->header(QNetworkRequest::ContentTypeHeader).toString(), QLatin1String("text/json")); + QVERIFY(reply->header(QNetworkRequest::ContentTypeHeader).toString().startsWith(QLatin1String("text/json"))); const auto products = Product::fromJson(reply->readAll()); QVERIFY(!findProduct(products, QLatin1String("org.kde.UserFeedback.UnitTestProduct")).isValid()); diff --git a/tests/auto/providertest.cpp b/tests/auto/providertest.cpp index 4b7c17e77af9eff46fae3a0329ccc739dbb30d13..756e1ce55d2f3c8f994b6770f19035eb4dcd7233 100644 --- a/tests/auto/providertest.cpp +++ b/tests/auto/providertest.cpp @@ -101,7 +101,7 @@ private slots: // retrieve data reply = RESTApi::listSamples(&client, p); QVERIFY(waitForFinished(reply)); - QCOMPARE(reply->header(QNetworkRequest::ContentTypeHeader).toString(), QLatin1String("text/json")); + QVERIFY(reply->header(QNetworkRequest::ContentTypeHeader).toString().startsWith(QLatin1String("text/json"))); auto doc = QJsonDocument::fromJson(reply->readAll()); QVERIFY(doc.isArray()); auto a = doc.array(); diff --git a/tests/auto/surveyapitest.cpp b/tests/auto/surveyapitest.cpp index 96d6e925e12a778b674df8fe2a43da0f4d319c00..edd89292079e5fd8dae712943dbfcb71149a735e 100644 --- a/tests/auto/surveyapitest.cpp +++ b/tests/auto/surveyapitest.cpp @@ -94,7 +94,7 @@ private slots: auto reply = RESTApi::listSurveys(&client, p); QVERIFY(waitForFinished(reply)); QCOMPARE(reply->error(), QNetworkReply::NoError); - QCOMPARE(reply->header(QNetworkRequest::ContentTypeHeader).toString(), QLatin1String("text/json")); + QVERIFY(reply->header(QNetworkRequest::ContentTypeHeader).toString().startsWith(QLatin1String("text/json"))); auto surveys = Survey::fromJson(reply->readAll()); QVERIFY(surveys.isEmpty());