Mercurial > trustbridge
view ui/tests/mainwindowtest.cpp @ 569:6677d4ecb6fd
Add codesignging certificates and Notes how they were generated.
The keys are intended to be public as they are test keys that
hold no value.
author | Andre Heinecke <aheinecke@intevation.de> |
---|---|
date | Fri, 23 May 2014 10:21:20 +0000 |
parents | aee3eb10bbba |
children | 2fd4f9980a2a |
line wrap: on
line source
/* Copyright (C) 2014 by Bundesamt für Sicherheit in der Informationstechnik * Software engineering by Intevation GmbH * * This file is Free Software under the GNU GPL (v>=2) * and comes with ABSOLUTELY NO WARRANTY! * See LICENSE.txt for details. */ #include "mainwindowtest.h" #include <QSignalSpy> #ifdef Q_OS_WIN Q_IMPORT_PLUGIN(QWindowsIntegrationPlugin) #else Q_IMPORT_PLUGIN(QXcbIntegrationPlugin) #endif MainWindowTest::MainWindowTest() : MainWindow(true) { } void MainWindowTest::closeApp() { emit closeCalled(); } void MainWindowTest::testInvalidUpdate() { // TODO } void MainWindowTest::testValidUpdate() { QSignalSpy closed(this, SIGNAL(closeCalled())); #ifdef Q_OS_WIN installNewSW(QString::fromLatin1("c:/fakeinst.exe"), QDateTime::currentDateTime()); #else installNewSW(QString::fromLatin1("fakeinst"), QDateTime::currentDateTime()); #endif QVERIFY(closed.count() == 1); } QTEST_MAIN(MainWindowTest);