Bug on argument order

This commit is contained in:
ea4k 2021-03-13 16:22:41 +01:00
parent 898cb032c7
commit 26cd4106df
4 changed files with 120 additions and 1 deletions

View File

@ -28,7 +28,7 @@
#include "utilities.h" #include "utilities.h"
//#include <QDebug> //#include <QDebug>
DataProxy_SQLite::DataProxy_SQLite(const QString &_softVersion, const QString &_parentFunction) DataProxy_SQLite::DataProxy_SQLite(const QString &_parentFunction, const QString &_softVersion)
{ {
//qDebug() << "DataProxy_SQLite::DataProxy_SQLite" << _softVersion << _parentFunction << endl; //qDebug() << "DataProxy_SQLite::DataProxy_SQLite" << _softVersion << _parentFunction << endl;

View File

@ -3,4 +3,5 @@ SUBDIRS=\
utilities \ utilities \
mainqsoentrywidget \ mainqsoentrywidget \
mainwindowsattab \ mainwindowsattab \
tst_dataproxy \
world world

View File

@ -0,0 +1,82 @@
#include <QtTest>
#include "../../src/dataproxy_sqlite.h"
#include "../../src/utilities.h"
/***************************************************************************
tst_dataproxy.h - description
-------------------
begin : Mar 2021
copyright : (C) 2021 by Jaime Robles
email : jaime@robles.es
***************************************************************************/
/*****************************************************************************
* This file is part of Testing suite of KLog. *
* *
* KLog is free software: you can redistribute it and/or modify *
* it under the terms of the GNU General Public License as published by *
* the Free Software Foundation, either version 3 of the License, or *
* (at your option) any later version. *
* *
* The testing suite of KLog is distributed in the hope that it will *
* be useful, but WITHOUT ANY WARRANTY; without even the implied *
* warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. *
* See the GNU General Public License for more details. *
* *
* You should have received a copy of the GNU General Public License *
* along with Testing suite of KLog. *
* If not, see <https://www.gnu.org/licenses/>. *
* *
*****************************************************************************/
class tst_DataProxy : public QObject
{
Q_OBJECT
public:
tst_DataProxy();
~tst_DataProxy();
private slots:
void initTestCase();
void cleanupTestCase();
void test_Constructor();
//void test_getProgresStepForDialog();
private:
DataProxy_SQLite *dataProxy;
Utilities *util;
};
tst_DataProxy::tst_DataProxy()
{
util = new Utilities;
dataProxy = new DataProxy_SQLite(Q_FUNC_INFO, util->getVersion ());
}
tst_DataProxy::~tst_DataProxy()
{
}
void tst_DataProxy::initTestCase()
{
}
void tst_DataProxy::cleanupTestCase()
{
}
void tst_DataProxy::test_Constructor()
{
QVERIFY2(util->getVersion() == "0.0", "Version failed");
}
QTEST_APPLESS_MAIN(tst_DataProxy)
#include "tst_dataproxy.moc"

View File

@ -0,0 +1,36 @@
QT += testlib \
gui \
sql \
widgets
CONFIG += qt console warn_on depend_includepath testcase
CONFIG -= app_bundle
TEMPLATE = app
HEADERS += \
../../src/dataproxy_sqlite.h \
../../src/utilities.h \
../../src/locator.h \
../../src/database.h \
../../src/qso.h \
../../src/klogdefinitions.h
SOURCES += tst_dataproxy.cpp \
../../src/utilities.cpp \
../../src/locator.cpp \
../../src/database.cpp \
../../src/qso.cpp \
../../src/dataproxy_sqlite.cpp
isEmpty(QMAKE_LRELEASE) {
win32|os2:QMAKE_LRELEASE = $$[QT_INSTALL_BINS]\lrelease.exe
else:QMAKE_LRELEASE = $$[QT_INSTALL_BINS]/lrelease
unix {
!exists($$QMAKE_LRELEASE) { QMAKE_LRELEASE = lrelease-qt5 }
} else {
!exists($$QMAKE_LRELEASE) { QMAKE_LRELEASE = lrelease }
}
}