diff options
Diffstat (limited to 'tests/shared/testhelper.h')
-rw-r--r-- | tests/shared/testhelper.h | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/tests/shared/testhelper.h b/tests/shared/testhelper.h index c6e6610f..5d082b5e 100644 --- a/tests/shared/testhelper.h +++ b/tests/shared/testhelper.h @@ -50,6 +50,7 @@ #include <QJsonDocument> #include <QJsonValue> #include <QObject> +#include <QProcess> #include <QStringList> QT_BEGIN_HEADER @@ -79,7 +80,8 @@ public: void waitForResponse(QList<QtJsonDb::QJsonDbRequest*> requests); void waitForResponseAndNotifications(QtJsonDb::QJsonDbRequest *request, QtJsonDb::QJsonDbWatcher *watcher, - int notificationsExpected); + int notificationsExpected, + int lastStateChangedExpected = 0); void waitForStatus(QtJsonDb::QJsonDbWatcher *watcher, QtJsonDb::QJsonDbWatcher::Status status); @@ -89,10 +91,14 @@ protected: QEventLoop mEventLoop; int mNotificationsReceived; int mNotificationsExpected; + int mLastStateChangedExpected; + int mLastStateChangedReceived; protected Q_SLOTS: void connectionError(QtJsonDb::QJsonDbConnection::ErrorCode code, QString msg); + void processFinished(int,QProcess::ExitStatus); + void requestFinished(); void requestError(QtJsonDb::QJsonDbRequest::ErrorCode code, QString msg); void requestStatusChanged(QtJsonDb::QJsonDbRequest::Status status); @@ -100,6 +106,7 @@ protected Q_SLOTS: void watcherNotificationsAvailable(int count); void watcherStatusChanged(QtJsonDb::QJsonDbWatcher::Status status); void watcherError(QtJsonDb::QJsonDbWatcher::ErrorCode code, QString msg); + void watcherLastStateNumberChanged(int stateNumber); void timeout(); private: |