diff options
author | Miikka Heikkinen <miikka.heikkinen@digia.com> | 2012-02-14 15:47:27 +0200 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2012-02-15 02:35:58 +0100 |
commit | fc8f92106d6743d4165de7d8a440b7e5dbd14391 (patch) | |
tree | 63c1c75953e2fee118ccbbc4f3d97deb89c667df | |
parent | c7d3f9be585b5aa4d0d53350a0a23f68ddd3c22f (diff) |
Remove fileLineEndingTest from networkselftest.
The fileLineEndingTest case doesn't test network in any way and it is
conceptually wrong, too, as any tests where line endings are an issue
should be handled with .gitattributes rather than forcing user to
check out the repo with unix line endings.
Task-number: QTBUG-24271
Change-Id: I73986993edc227cb68b8f61d51cc1cf458d20989
Reviewed-by: Shane Kearns <ext-shane.2.kearns@nokia.com>
-rw-r--r-- | tests/auto/other/networkselftest/tst_networkselftest.cpp | 26 |
1 files changed, 0 insertions, 26 deletions
diff --git a/tests/auto/other/networkselftest/tst_networkselftest.cpp b/tests/auto/other/networkselftest/tst_networkselftest.cpp index c1a3cd17d2..99d4ac9522 100644 --- a/tests/auto/other/networkselftest/tst_networkselftest.cpp +++ b/tests/auto/other/networkselftest/tst_networkselftest.cpp @@ -70,7 +70,6 @@ private slots: void serverReachability(); void remotePortsOpen_data(); void remotePortsOpen(); - void fileLineEndingTest(); // specific protocol tests void ftpServer(); @@ -458,31 +457,6 @@ void tst_NetworkSelfTest::remotePortsOpen() QVERIFY(socket.state() == QAbstractSocket::ConnectedState); } - -void tst_NetworkSelfTest::fileLineEndingTest() -{ - QString referenceName = SRCDIR "/rfc3252.txt"; - long long expectedReferenceSize = 25962; - - QString lineEndingType("LF"); - - QFile reference(referenceName); - QVERIFY(reference.open(QIODevice::ReadOnly)); - QByteArray byteLine = reference.readLine(); - if(byteLine.endsWith("\r\n")) - lineEndingType = "CRLF"; - else if(byteLine.endsWith("\r")) - lineEndingType = "CR"; - - QString referenceAsTextData; - QFile referenceAsText(referenceName); - QVERIFY(referenceAsText.open(QIODevice::ReadOnly)); - referenceAsTextData = referenceAsText.readAll(); - - QVERIFY2(expectedReferenceSize == referenceAsTextData.length(), QString("Reference file %1 has %2 as line ending and file size not matching - Git checkout issue !?!").arg(referenceName, lineEndingType).toLocal8Bit()); - QVERIFY2(!lineEndingType.compare("LF"), QString("Reference file %1 has %2 as line ending - Git checkout issue !?!").arg(referenceName, lineEndingType).toLocal8Bit()); -} - static QList<Chat> ftpChat(const QByteArray &userSuffix = QByteArray()) { QList<Chat> rv; |