Commit cf85a838 authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

Use logSynchronizeResource

parent 7090c4de
......@@ -50,8 +50,8 @@ QString ImportAddressbookJobInterfaceTestImpl::createResource(const QString &res
void ImportAddressbookJobInterfaceTestImpl::synchronizeResource(const QStringList &lst)
{
mLogCreateResource->logSynchronizeResource(lst);
slotNextStep();
//TODO
}
ImportAddressbookJobInterfaceTest::ImportAddressbookJobInterfaceTest(QObject *parent)
......
......@@ -50,8 +50,8 @@ QString ImportAlarmJobInterfaceTestImpl::createResource(const QString &resources
void ImportAlarmJobInterfaceTestImpl::synchronizeResource(const QStringList &lst)
{
mLogCreateResource->logSynchronizeResource(lst);
slotNextStep();
//TODO
}
ImportAlarmJobInterfaceTest::ImportAlarmJobInterfaceTest(QObject *parent)
......
......@@ -50,7 +50,8 @@ QString ImportCalendarJobInterfaceTestImpl::createResource(const QString &resour
void ImportCalendarJobInterfaceTestImpl::synchronizeResource(const QStringList &lst)
{
//TODO
mLogCreateResource->logSynchronizeResource(lst);
slotNextStep();
}
ImportCalendarJobInterfaceTest::ImportCalendarJobInterfaceTest(QObject *parent)
......
......@@ -39,6 +39,13 @@ void LogCreatingResource::appendText(const QString &str)
//TODO
}
void LogCreatingResource::logSynchronizeResource(const QStringList &lst)
{
if (lst.isEmpty()) {
appendText(lst.join(QLatin1Char('\n')));
}
}
QString LogCreatingResource::logPath() const
{
return mTmpLogFile->fileName();
......
......@@ -31,6 +31,7 @@ public:
void appendText(const QString &str);
Q_REQUIRED_RESULT QString logPath() const;
void logCreateResource(const QString &resources, const QString &name, const QMap<QString, QVariant> &settings, bool synchronizeTree);
void logSynchronizeResource(const QStringList &lst);
private:
QTemporaryFile *mTmpLogFile = nullptr;
};
......
......@@ -43,7 +43,7 @@ Akonadi::Collection::Id ImportMailJobInterfaceTestImpl::convertFolderPathToColle
void ImportMailJobInterfaceTestImpl::synchronizeResource(const QStringList &lst)
{
qDebug() << " void ImportMailJobInterfaceTestImpl::synchronizeResource(const QStringList &lst)" << lst;
mLogCreateResource->logSynchronizeResource(lst);
slotNextStep();
//TODO
}
......
......@@ -52,9 +52,7 @@ QString ImportNotesJobInterfaceTestImpl::createResource(const QString &resources
void ImportNotesJobInterfaceTestImpl::synchronizeResource(const QStringList &lst)
{
//TODO log it!
qDebug() << " void ImportNotesJobInterfaceTestImpl::synchronizeResource(const QStringList &lst) TODO IMPLEMENT" << lst;
mLogCreateResource->appendText(lst.join(QLatin1Char('\n')));
mLogCreateResource->logSynchronizeResource(lst);
slotNextStep();
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment