diff options
Diffstat (limited to 'src-qt5/src-cpp/tests')
-rw-r--r-- | src-qt5/src-cpp/tests/main.cpp | 38 | ||||
-rw-r--r-- | src-qt5/src-cpp/tests/test.pro | 7 |
2 files changed, 45 insertions, 0 deletions
diff --git a/src-qt5/src-cpp/tests/main.cpp b/src-qt5/src-cpp/tests/main.cpp new file mode 100644 index 00000000..682c318a --- /dev/null +++ b/src-qt5/src-cpp/tests/main.cpp @@ -0,0 +1,38 @@ +#include <QDebug> +#include <QApplication> + +#include <framework-OSInterface.h> + +/* +class tester : public QObject{ + Q_OBJECT +public slots: + void finished(){ QApplication::exit(0); } + +public: + QTimer *timer; + + tester(){ + timer = new QTimer(this); + timer->setInterval(5000); + timer->setSingleShot(true); + connect(timer, SIGNAL(timeout()), this, SLOT(finished()) ); + } + +}; +*/ + +int main(int argc, char** argv){ + + QApplication A(argc,argv); + OSInterface OS; + OS.start(); + QTimer *timer = new QTimer(); + timer->setInterval(5000); + timer->setSingleShot(true); + QObject::connect(timer, SIGNAL(timeout()), &A, SLOT(quit()) ); + timer->start(); + int ret = A.exec(); + qDebug() << " - Finished"; + return ret; +} diff --git a/src-qt5/src-cpp/tests/test.pro b/src-qt5/src-cpp/tests/test.pro new file mode 100644 index 00000000..425e7de6 --- /dev/null +++ b/src-qt5/src-cpp/tests/test.pro @@ -0,0 +1,7 @@ +QT = core gui widgets + +include(../framework-OSInterface.pri) + +TARGET = test + +SOURCES += main.cpp |