aboutsummaryrefslogtreecommitdiffstats
path: root/lang/qt/tests/t-ownertrust.cpp
diff options
context:
space:
mode:
authorAndre Heinecke <[email protected]>2016-08-09 12:10:15 +0000
committerAndre Heinecke <[email protected]>2016-08-09 12:23:51 +0000
commitf209ec8f581ae597b37f2e3a5e452e4b53b2d4c7 (patch)
tree810a34c62c736aa302cb4e955086d96bf7276b0e /lang/qt/tests/t-ownertrust.cpp
parentQt: Add support for EncryptJobs with generic flags (diff)
downloadgpgme-f209ec8f581ae597b37f2e3a5e452e4b53b2d4c7.tar.gz
gpgme-f209ec8f581ae597b37f2e3a5e452e4b53b2d4c7.zip
Qt: Add encryption test and refactor testsuite
* lang/qt/tests/Makefile.am: Add t-encrypt and t-support. * lang/qt/tests/t-support.cpp, lang/qt/tests/t-support.c (QGpgMETest): New. Class to handle common cleanup / init. * lang/qt/tests/t-keylist.cpp, lang/qt/tests/t-keylocate.cpp, lang/qt/tests/t-ownertrust.cpp, lang/qt/tests/t-tofuinfo.cpp: Inherit QGpgMETest. * lang/qt/tests/t-encrypt.cpp: New. Test Symetric and Asymectric encryption. Mixed encryption test is disabled.
Diffstat (limited to 'lang/qt/tests/t-ownertrust.cpp')
-rw-r--r--lang/qt/tests/t-ownertrust.cpp15
1 files changed, 3 insertions, 12 deletions
diff --git a/lang/qt/tests/t-ownertrust.cpp b/lang/qt/tests/t-ownertrust.cpp
index 8784a796..b9efffda 100644
--- a/lang/qt/tests/t-ownertrust.cpp
+++ b/lang/qt/tests/t-ownertrust.cpp
@@ -37,10 +37,12 @@
#include "keylistresult.h"
#include "changeownertrustjob.h"
+#include "t-support.h"
+
using namespace QGpgME;
using namespace GpgME;
-class ChangeOwnerTrustTest: public QObject
+class ChangeOwnerTrustTest: public QGpgMETest
{
Q_OBJECT
@@ -98,17 +100,6 @@ private Q_SLOTS:
key = keys.front();
Q_ASSERT (key.ownerTrust() == Key::Unknown);
}
-
- void initTestCase()
- {
- const QString gpgHome = qgetenv("GNUPGHOME");
- QVERIFY2(!gpgHome.isEmpty(), "GNUPGHOME environment variable is not set.");
- }
-
- void cleanupTestCase()
- {
- QCoreApplication::sendPostedEvents();
- }
};
QTEST_MAIN(ChangeOwnerTrustTest)