From: Olivier Goffart Date: Mon, 5 Nov 2018 11:03:39 +0000 (+0100) Subject: RemoteDiscoveryTest: Fix after the merge from 2.5 X-Git-Tag: archive/raspbian/3.16.7-1_deb13u1+rpi1~1^2~12^2~21^2~468^2~441 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=2c9b66fe6952a7f33537099db48fa9b17c740e6b;p=nextcloud-desktop.git RemoteDiscoveryTest: Fix after the merge from 2.5 The new discovery's message is slightly different --- diff --git a/test/testremotediscovery.cpp b/test/testremotediscovery.cpp index 1c1dac960..43ef76a07 100644 --- a/test/testremotediscovery.cpp +++ b/test/testremotediscovery.cpp @@ -56,14 +56,16 @@ private slots: QTest::addColumn("errorKind"); QTest::addColumn("expectedErrorString"); - QTest::newRow("404") << 404 << "File or directory not found: B"; - QTest::newRow("500") << 500 << "An error occurred while opening a folder B: Internal Server Fake Error"; - QTest::newRow("503") << 503 << "An error occurred while opening a folder B: Internal Server Fake Error"; + QString httpErrorMessage = "Server replied with an error while reading directory 'B' : Internal Server Fake Error"; + + QTest::newRow("404") << 404 << httpErrorMessage; + QTest::newRow("500") << 500 << httpErrorMessage; + QTest::newRow("503") << 503 << httpErrorMessage; // 200 should be an error since propfind should return 207 - QTest::newRow("200") << 200 << "An error occurred while opening a folder B: Internal Server Fake Error"; - QTest::newRow("InvalidXML") << +InvalidXML << "An error occurred while opening a folder B: Unknown error"; - QTest::newRow("MissingPermissions") << +MissingPermissions << "A HTTP transmission error happened. B: The server file discovery reply is missing data."; - QTest::newRow("Timeout") << +Timeout << "An error occurred while opening a folder B: Operation canceled"; + QTest::newRow("200") << 200 << httpErrorMessage; + QTest::newRow("InvalidXML") << +InvalidXML << "error while reading directory 'B' : Unknown error"; + QTest::newRow("MissingPermissions") << +MissingPermissions << "error while reading directory 'B' : The server file discovery reply is missing data."; + QTest::newRow("Timeout") << +Timeout << "error while reading directory 'B' : Operation canceled"; }