Commit 6e8a3d33 authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

Fix import note autotest

parent 237c41e2
...@@ -5,4 +5,4 @@ Port=12 ...@@ -5,4 +5,4 @@ Port=12
SenderID=VV SenderID=VV
[SelectNoteFolder] [SelectNoteFolder]
DefaultFolder=foo/bla bla/bli31 DefaultFolder=41
...@@ -19,7 +19,7 @@ ...@@ -19,7 +19,7 @@
#include "testimportfile.h" #include "testimportfile.h"
#include "archivestorage.h" #include "archivestorage.h"
#include "utils.h"
#include "abstractimportexportjob.h" #include "abstractimportexportjob.h"
#include "compareimportfile.h" #include "compareimportfile.h"
...@@ -49,6 +49,12 @@ void TestImportFile::start() ...@@ -49,6 +49,12 @@ void TestImportFile::start()
qputenv("XDG_CONFIG_HOME", mExtractPath.toLatin1() + "/config"); qputenv("XDG_CONFIG_HOME", mExtractPath.toLatin1() + "/config");
qDebug() << " mExtractPath.toLatin1() " << mExtractPath.toLatin1() ; qDebug() << " mExtractPath.toLatin1() " << mExtractPath.toLatin1() ;
const int version = Utils::archiveVersion(mArchiveStorage->archive());
QVERIFY(version <= Utils::currentArchiveVersion());
mAbstractImportExportJob->setArchiveVersion(version);
QSignalSpy finish(mAbstractImportExportJob, &AbstractImportExportJob::jobFinished); QSignalSpy finish(mAbstractImportExportJob, &AbstractImportExportJob::jobFinished);
QSignalSpy error(mAbstractImportExportJob, &AbstractImportExportJob::error); QSignalSpy error(mAbstractImportExportJob, &AbstractImportExportJob::error);
mAbstractImportExportJob->start(); mAbstractImportExportJob->start();
......
...@@ -101,9 +101,9 @@ KZip *openZip(const QString &filename, QString &errorMsg); ...@@ -101,9 +101,9 @@ KZip *openZip(const QString &filename, QString &errorMsg);
PIMDATAEXPORTER_EXPORT void storeDataExportInfo(KZip *archive); PIMDATAEXPORTER_EXPORT void storeDataExportInfo(KZip *archive);
PIMDATAEXPORTER_EXPORT void addVersion(KZip *archive); PIMDATAEXPORTER_EXPORT void addVersion(KZip *archive);
Q_REQUIRED_RESULT int archiveVersion(KZip *archive); PIMDATAEXPORTER_EXPORT Q_REQUIRED_RESULT int archiveVersion(KZip *archive);
Q_REQUIRED_RESULT int currentArchiveVersion(); PIMDATAEXPORTER_EXPORT Q_REQUIRED_RESULT int currentArchiveVersion();
PIMDATAEXPORTER_EXPORT Q_REQUIRED_RESULT QString appTypeToI18n(AppsType type); PIMDATAEXPORTER_EXPORT Q_REQUIRED_RESULT QString appTypeToI18n(AppsType type);
PIMDATAEXPORTER_EXPORT Q_REQUIRED_RESULT QString storedTypeToI18n(StoredType type); PIMDATAEXPORTER_EXPORT Q_REQUIRED_RESULT QString storedTypeToI18n(StoredType type);
} }
......
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