on xenial help sign in
cleanup
8a22c11Michael Zanetti
plugins/Unity/Launcher/desktopfilehandler.cpp−1
@@ -24,7 +24,6 @@
24#include <QDir>
24#include <QDir>
25#include <QSettings>
25#include <QSettings>
26#include <QLocale>
26#include <QLocale>
27−#include <QDebug>
28
27
29#include <libintl.h>
28#include <libintl.h>
30
29
tests/plugins/Unity/Launcher/launchermodeltest.cpp+4−10
@@ -419,13 +419,6 @@ private Q_SLOTS:
419 QDir::setCurrent(oldCurrent);
419 QDir::setCurrent(oldCurrent);
420 }
420 }
421
421
422− void testSettings_data() {
423− QTest::addColumn<QStringList>("storedList");
424−
425− QTest::newRow("2 stored") << (QStringList() << "abs-icon" << "no-icon");
426− QTest::newRow("1 stored") << (QStringList() << "abs-icon");
427− }
428−
429 void testSettings() {
422 void testSettings() {
430 GSettings *settings = launcherModel->m_settings;
423 GSettings *settings = launcherModel->m_settings;
431
424
@@ -453,10 +446,11 @@ private Q_SLOTS:
453 // Check if it disappeared from the frontend too
446 // Check if it disappeared from the frontend too
454 QCOMPARE(launcherModel->rowCount(), 1);
447 QCOMPARE(launcherModel->rowCount(), 1);
455
448
456− // Add them back:
449+ // Add them back but in reverse order
457− settings->setStoredApplications(QStringList() << "abs-icon" << "no-icon");
450+ settings->setStoredApplications(QStringList() << "no-icon" << "abs-icon");
458 QCOMPARE(launcherModel->rowCount(), 2);
451 QCOMPARE(launcherModel->rowCount(), 2);
459−
452+ QCOMPARE(launcherModel->get(0)->appId(), QString("no-icon"));
453+ QCOMPARE(launcherModel->get(1)->appId(), QString("abs-icon"));
460 }
454 }
461};
455};
462
456