Commit 237c41e2 authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

Allow to compare import file

parent b578dcba
......@@ -45,6 +45,13 @@ void CompareImportFile::compareFile()
qDebug() << "List File : " << archiveList;
}
QVERIFY(equal);
for (QString file : archiveList) {
file.replace(QStringLiteral("configs/"), QStringLiteral("config/"));
if (file == QLatin1String("information/exportdatatype.xml") || file == QLatin1String("information/VERSION_2")) {
continue;
}
CompareFileHelper::compareFile(mListFilePath + QStringLiteral("/references/") + file, mInstallPath + QLatin1Char('/') + file);
}
}
QString CompareImportFile::archiveFilePath() const
......@@ -67,3 +74,13 @@ void CompareImportFile::setListFilePath(const QString &listFilePath)
mListFilePath = listFilePath;
}
QString CompareImportFile::installPath() const
{
return mInstallPath;
}
void CompareImportFile::setInstallPath(const QString &installPath)
{
mInstallPath = installPath;
}
......@@ -36,9 +36,13 @@ public:
Q_REQUIRED_RESULT QString listFilePath() const;
void setListFilePath(const QString &listFilePath);
Q_REQUIRED_RESULT QString installPath() const;
void setInstallPath(const QString &installPath);
private:
QString mArchiveFilePath;
QString mListFilePath;
QString mInstallPath;
};
#endif // COMPAREIMPORTFILE_H
[Event/receivednotes]
Action=Sound|Popup
Execute=
Logfile=
Sound=
TTS=
[Network]
KnownHosts=199.168.1.13
NoteHostDialogSize=596,334
Port=12
SenderID=VV
[SelectNoteFolder]
DefaultFolder=foo/bla bla/bli31
[$Version]
update_info=noteglobalsettings.upd:initial-noteagent-migration,noteglobalsettings.upd:selectcollection-noteagent-migration
[AgentTypeDialog]
Size=979,637
[Display]
width=260
[DownloadDialog Settings]
Height 1080=522
Width 1920=700
[Editor]
titlefont=Liberation Sans,12,-1,5,50,0,0,0,0,0,Regular
[KFileDialog Settings]
Height 1080=540
Width 1920=960
[KNoteDeleteSelectedNotesDialog]
Size=300,200
[KNoteFindDialog]
Size=461,270
[KNotePrintSelectedNotesDialog]
Size=960,656
[KNoteSimpleConfigDialog]
Size=600,400
[KNotesKeyDialog]
Size=1120,685
[KPimPrintPreviewDialog]
Size=1054,732
[Migratekde4]
Version=1
[Misc]
SystemTrayShowNotes=true
[SelectedNotefolderDialog]
Size=600,400
......@@ -60,6 +60,7 @@ void TestImportFile::start()
CompareImportFile compareExportFile;
compareExportFile.setArchiveFilePath(mArchivePath);
compareExportFile.setListFilePath(mPathConfig);
compareExportFile.setInstallPath(mExtractPath);
compareExportFile.compareFile();
}
......
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