Make test better

This commit is contained in:
Albert Vaca Cintora 2019-02-13 00:10:30 +01:00
parent 8142a2c92f
commit 695a0e1b6b

View file

@ -126,13 +126,15 @@ class TestSendFile : public QObject
ft->start();
QVERIFY(spyTransfer.count() || spyTransfer.wait(1000000000));
QVERIFY(spyTransfer.count() || spyTransfer.wait());
if (ft->error()) qWarning() << "fterror" << ft->errorString();
if (ft->error()) {
qWarning() << "fterror" << ft->errorString();
}
QCOMPARE(ft->error(), 0);
// HACK | FIXME: Why does this break the test?
//QCOMPARE(spyUpload.count(), 1);
QCOMPARE(spyUpload.count(), 1);
QFile resultFile(destFile), originFile(aFile);
QVERIFY(resultFile.open(QIODevice::ReadOnly));