Commit 4b155567 authored by Laurent Montel's avatar Laurent Montel 😁

Modernize code (using auto)

parent 10ab49fd
Pipeline #39324 passed with stage
in 16 minutes and 5 seconds
......@@ -26,7 +26,7 @@ void FilterBalsaMailTest::canNotImportDataEmptyPath()
{
MailImporter::FilterBalsa filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QString());
......@@ -38,7 +38,7 @@ void FilterBalsaMailTest::canNotImportDataUnknowPath()
{
MailImporter::FilterBalsa filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QStringLiteral("/foo/kde/bla/toto/"));
......@@ -50,7 +50,7 @@ void FilterBalsaMailTest::canNotImportDataWhenHomeDirSelected()
{
MailImporter::FilterBalsa filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QDir::homePath());
......
......@@ -26,7 +26,7 @@ void FilterClawsMailTest::canNotImportDataEmptyPath()
{
MailImporter::FilterClawsMail filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QString());
......@@ -38,7 +38,7 @@ void FilterClawsMailTest::canNotImportDataUnknowPath()
{
MailImporter::FilterClawsMail filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QStringLiteral("/foo/kde/bla/toto/"));
......@@ -50,7 +50,7 @@ void FilterClawsMailTest::canNotImportDataWhenHomeDirSelected()
{
MailImporter::FilterClawsMail filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QDir::homePath());
......
......@@ -45,7 +45,7 @@ void FilterIcedoveTest::canNotImportDataEmptyPath()
{
MailImporter::FilterIcedove filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QString());
......@@ -57,7 +57,7 @@ void FilterIcedoveTest::canNotImportDataUnknowPath()
{
MailImporter::FilterIcedove filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QStringLiteral("/foo/kde/bla/toto/"));
......@@ -69,7 +69,7 @@ void FilterIcedoveTest::canNotImportDataWhenHomeDirSelected()
{
MailImporter::FilterIcedove filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QDir::homePath());
......
......@@ -26,7 +26,7 @@ void FilterLnotesTest::canNotImportDataEmptyPath()
{
MailImporter::FilterLNotes filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
//TODO implement it
......@@ -39,7 +39,7 @@ void FilterLnotesTest::canNotImportDataUnknowPath()
{
MailImporter::FilterLNotes filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
//filter.importMails(QStringLiteral("/foo/kde/bla/toto/"));
......
......@@ -26,7 +26,7 @@ void FilterMailAppTest::canNotImportDataEmptyPath()
{
MailImporter::FilterMailApp filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QString());
......@@ -38,7 +38,7 @@ void FilterMailAppTest::canNotImportDataUnknowPath()
{
MailImporter::FilterMailApp filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QStringLiteral("/foo/kde/bla/toto/"));
......
......@@ -26,7 +26,7 @@ void FilterMAilmangzipTest::canNotImportDataEmptyPath()
{
MailImporter::FilterMailmanGzip filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QStringList());
......
......@@ -26,7 +26,7 @@ void FilterMBoxTest::canNotImportDataEmptyPath()
{
MailImporter::FilterMBox filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QStringList());
......@@ -38,7 +38,7 @@ void FilterMBoxTest::canNotImportDataUnknowPath()
{
MailImporter::FilterMBox filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QStringList() << QStringLiteral("/foo/kde/bla/toto/"));
......
......@@ -26,7 +26,7 @@ void FilterPlainTest::canNotImportDataEmptyPath()
{
MailImporter::FilterPlain filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QString());
......@@ -38,7 +38,7 @@ void FilterPlainTest::canNotImportDataUnknowPath()
{
MailImporter::FilterPlain filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QStringLiteral("/foo/kde/bla/toto/"));
......
......@@ -27,7 +27,7 @@ void FilterSylpheedTest::canNotImportDataEmptyPath()
{
MailImporter::FilterSylpheed filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QString());
......@@ -39,7 +39,7 @@ void FilterSylpheedTest::canNotImportDataUnknowPath()
{
MailImporter::FilterSylpheed filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QStringLiteral("/foo/kde/bla/toto/"));
......@@ -51,7 +51,7 @@ void FilterSylpheedTest::canNotImportDataWhenHomeDirSelected()
{
MailImporter::FilterSylpheed filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QDir::homePath());
......
......@@ -26,7 +26,7 @@ void FilterTheBatTest::canNotImportDataEmptyPath()
{
MailImporter::FilterTheBat filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QString());
......@@ -38,7 +38,7 @@ void FilterTheBatTest::canNotImportDataUnknowPath()
{
MailImporter::FilterTheBat filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QStringLiteral("/foo/kde/bla/toto/"));
......@@ -50,7 +50,7 @@ void FilterTheBatTest::canNotImportDataWhenHomeDirSelected()
{
MailImporter::FilterTheBat filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QDir::homePath());
......
......@@ -45,7 +45,7 @@ void FilterThunderBirdTest::canNotImportDataEmptyPath()
{
MailImporter::FilterThunderbird filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QString());
......@@ -57,7 +57,7 @@ void FilterThunderBirdTest::canNotImportDataUnknowPath()
{
MailImporter::FilterThunderbird filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QStringLiteral("/foo/kde/bla/toto/"));
......@@ -69,7 +69,7 @@ void FilterThunderBirdTest::canNotImportDataWhenHomeDirSelected()
{
MailImporter::FilterThunderbird filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QDir::homePath());
......
......@@ -18,9 +18,9 @@ SelectThunderbirdProfileDialogTest::SelectThunderbirdProfileDialogTest(QObject *
void SelectThunderbirdProfileDialogTest::shouldHaveDefaultValue()
{
MailImporter::SelectThunderbirdProfileDialog dlg;
MailImporter::SelectThunderbirdProfileWidget *widget = dlg.findChild<MailImporter::SelectThunderbirdProfileWidget *>(QStringLiteral("selectprofile"));
auto *widget = dlg.findChild<MailImporter::SelectThunderbirdProfileWidget *>(QStringLiteral("selectprofile"));
QVERIFY(widget);
QDialogButtonBox *buttonBox = dlg.findChild<QDialogButtonBox *>(QStringLiteral("buttonBox"));
auto *buttonBox = dlg.findChild<QDialogButtonBox *>(QStringLiteral("buttonBox"));
QVERIFY(buttonBox);
}
......
......@@ -115,7 +115,7 @@ bool FilterKMailArchive::importDirectory(const KArchiveDirectory *directory, con
const KArchiveEntry *const entry = directory->entry(entryName);
if (entry->isDirectory()) {
const KArchiveDirectory *dir = static_cast<const KArchiveDirectory *>(entry);
const auto *dir = static_cast<const KArchiveDirectory *>(entry);
if (!dir->name().startsWith(QLatin1Char('.'))) {
if (!importFolder(dir, folderPath + QLatin1Char('/') + dir->name())) {
......
......@@ -19,7 +19,7 @@ SelectThunderbirdProfileDialog::SelectThunderbirdProfileDialog(QWidget *parent)
{
setWindowTitle(i18nc("@title:window", "Select thunderbird profile"));
setModal(true);
QVBoxLayout *topLayout = new QVBoxLayout(this);
auto *topLayout = new QVBoxLayout(this);
mSelectProfile = new SelectThunderbirdProfileWidget(this);
mSelectProfile->setObjectName(QStringLiteral("selectprofile"));
......
......@@ -26,7 +26,7 @@ void FilterBalsaMailTest::canNotImportDataEmptyPath()
{
MailImporter::FilterBalsa filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QString());
......@@ -38,7 +38,7 @@ void FilterBalsaMailTest::canNotImportDataUnknowPath()
{
MailImporter::FilterBalsa filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QStringLiteral("/foo/kde/bla/toto/"));
......@@ -50,7 +50,7 @@ void FilterBalsaMailTest::canNotImportDataWhenHomeDirSelected()
{
MailImporter::FilterBalsa filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QDir::homePath());
......
......@@ -26,7 +26,7 @@ void FilterClawsMailTest::canNotImportDataEmptyPath()
{
MailImporter::FilterClawsMail filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QString());
......@@ -38,7 +38,7 @@ void FilterClawsMailTest::canNotImportDataUnknowPath()
{
MailImporter::FilterClawsMail filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QStringLiteral("/foo/kde/bla/toto/"));
......@@ -50,7 +50,7 @@ void FilterClawsMailTest::canNotImportDataWhenHomeDirSelected()
{
MailImporter::FilterClawsMail filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QDir::homePath());
......
......@@ -45,7 +45,7 @@ void FilterIcedoveTest::canNotImportDataEmptyPath()
{
MailImporter::FilterIcedove filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QString());
......@@ -57,7 +57,7 @@ void FilterIcedoveTest::canNotImportDataUnknowPath()
{
MailImporter::FilterIcedove filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QStringLiteral("/foo/kde/bla/toto/"));
......@@ -69,7 +69,7 @@ void FilterIcedoveTest::canNotImportDataWhenHomeDirSelected()
{
MailImporter::FilterIcedove filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QDir::homePath());
......
......@@ -26,7 +26,7 @@ void FilterLnotesTest::canNotImportDataEmptyPath()
{
MailImporter::FilterLNotes filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
//TODO implement it
......@@ -39,7 +39,7 @@ void FilterLnotesTest::canNotImportDataUnknowPath()
{
MailImporter::FilterLNotes filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
//filter.importMails(QStringLiteral("/foo/kde/bla/toto/"));
......
......@@ -26,7 +26,7 @@ void FilterMailAppTest::canNotImportDataEmptyPath()
{
MailImporter::FilterMailApp filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QString());
......@@ -38,7 +38,7 @@ void FilterMailAppTest::canNotImportDataUnknowPath()
{
MailImporter::FilterMailApp filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QStringLiteral("/foo/kde/bla/toto/"));
......
......@@ -26,7 +26,7 @@ void FilterMAilmangzipTest::canNotImportDataEmptyPath()
{
MailImporter::FilterMailmanGzip filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QStringList());
......
......@@ -26,7 +26,7 @@ void FilterMBoxTest::canNotImportDataEmptyPath()
{
MailImporter::FilterMBox filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QStringList());
......@@ -38,7 +38,7 @@ void FilterMBoxTest::canNotImportDataUnknowPath()
{
MailImporter::FilterMBox filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QStringList() << QStringLiteral("/foo/kde/bla/toto/"));
......
......@@ -26,7 +26,7 @@ void FilterPlainTest::canNotImportDataEmptyPath()
{
MailImporter::FilterPlain filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QString());
......@@ -38,7 +38,7 @@ void FilterPlainTest::canNotImportDataUnknowPath()
{
MailImporter::FilterPlain filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QStringLiteral("/foo/kde/bla/toto/"));
......
......@@ -27,7 +27,7 @@ void FilterSylpheedTest::canNotImportDataEmptyPath()
{
MailImporter::FilterSylpheed filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QString());
......@@ -39,7 +39,7 @@ void FilterSylpheedTest::canNotImportDataUnknowPath()
{
MailImporter::FilterSylpheed filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QStringLiteral("/foo/kde/bla/toto/"));
......@@ -51,7 +51,7 @@ void FilterSylpheedTest::canNotImportDataWhenHomeDirSelected()
{
MailImporter::FilterSylpheed filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QDir::homePath());
......
......@@ -26,7 +26,7 @@ void FilterTheBatTest::canNotImportDataEmptyPath()
{
MailImporter::FilterTheBat filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QString());
......@@ -38,7 +38,7 @@ void FilterTheBatTest::canNotImportDataUnknowPath()
{
MailImporter::FilterTheBat filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QStringLiteral("/foo/kde/bla/toto/"));
......@@ -50,7 +50,7 @@ void FilterTheBatTest::canNotImportDataWhenHomeDirSelected()
{
MailImporter::FilterTheBat filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QDir::homePath());
......
......@@ -45,7 +45,7 @@ void FilterThunderBirdTest::canNotImportDataEmptyPath()
{
MailImporter::FilterThunderbird filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QString());
......@@ -57,7 +57,7 @@ void FilterThunderBirdTest::canNotImportDataUnknowPath()
{
MailImporter::FilterThunderbird filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QStringLiteral("/foo/kde/bla/toto/"));
......@@ -69,7 +69,7 @@ void FilterThunderBirdTest::canNotImportDataWhenHomeDirSelected()
{
MailImporter::FilterThunderbird filter;
MailImporter::FilterInfo info;
FilterImporterTest *importerTest = new FilterImporterTest(&info);
auto *importerTest = new FilterImporterTest(&info);
filter.setFilterImporter(importerTest);
filter.setFilterInfo(&info);
filter.importMails(QDir::homePath());
......
......@@ -164,7 +164,7 @@ Akonadi::Collection FilterImporterAkonadi::parseFolderString(const QString &fold
Akonadi::Collection FilterImporterAkonadi::addSubCollection(const Akonadi::Collection &baseCollection, const QString &newCollectionPathName)
{
// Ensure that the collection doesn't already exsit, if it does just return it.
Akonadi::CollectionFetchJob *fetchJob = new Akonadi::CollectionFetchJob(baseCollection,
auto *fetchJob = new Akonadi::CollectionFetchJob(baseCollection,
Akonadi::CollectionFetchJob::FirstLevel);
if (!fetchJob->exec()) {
mInfo->alert(i18n("<b>Warning:</b> Could not check that the folder already exists. Reason: %1",
......@@ -183,7 +183,7 @@ Akonadi::Collection FilterImporterAkonadi::addSubCollection(const Akonadi::Colle
newSubCollection.setParentCollection(baseCollection);
newSubCollection.setName(newCollectionPathName);
Akonadi::CollectionCreateJob *job = new Akonadi::CollectionCreateJob(newSubCollection);
auto *job = new Akonadi::CollectionCreateJob(newSubCollection);
if (!job->exec()) {
mInfo->alert(i18n("<b>Error:</b> Could not create folder. Reason: %1",
job->errorString()));
......
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