Mercurial > trustbridge
diff ui/tests/certlistparsertest.cpp @ 88:abc76b750ea8
Fix extended list test. Add Benchmarking again
author | Andre Heinecke <aheinecke@intevation.de> |
---|---|
date | Thu, 20 Mar 2014 16:58:55 +0000 |
parents | be13e5e0a98f |
children | b0b1375dfd40 |
line wrap: on
line diff
--- a/ui/tests/certlistparsertest.cpp Thu Mar 20 16:23:31 2014 +0000 +++ b/ui/tests/certlistparsertest.cpp Thu Mar 20 16:58:55 2014 +0000 @@ -7,7 +7,10 @@ void CertListTest::testValidList() { const char *fname = "list-valid-signed.txt"; - QFile validList(fname); + + QDir dataDir = QDir(SOURCE_DIR"/data/"); + QString fileName = dataDir.absoluteFilePath(fname); + QFile validList(fileName); validList.open(QIODevice::ReadOnly); QString validData = QString::fromLatin1(validList.readAll()); QStringList instLines; @@ -20,7 +23,7 @@ QVERIFY(certList->rawData() == validData.toLatin1()); const QList<Certificate> instList = certList->getInstallCertificates(); - const QList<Certificate> remoList = certList->getInstallCertificates(); + const QList<Certificate> remoList = certList->getRemoveCertificates(); foreach (QString act, validData.split("\r\n")) { if (act.startsWith("I:")) { @@ -114,7 +117,7 @@ { const char *fname = "list-valid-signed.txt"; - QBENCHMARK_ONCE { + QBENCHMARK{ CertificateList *certList = testWithFile(fname); delete certList; }