File indexing completed on 2024-10-06 06:40:35
0001 /* 0002 This file is part of the KDE libraries 0003 SPDX-FileCopyrightText: 2016 David Faure <faure@kde.org> 0004 0005 SPDX-License-Identifier: LGPL-2.0-or-later 0006 */ 0007 0008 #include <kicondialog.h> 0009 0010 #include <QStandardPaths> 0011 #include <QTest> 0012 0013 #include <KConfigGroup> 0014 #include <KSharedConfig> 0015 0016 class KIconDialogTest : public QObject 0017 { 0018 Q_OBJECT 0019 0020 private Q_SLOTS: 0021 void initTestCase() 0022 { 0023 QStandardPaths::setTestModeEnabled(true); 0024 0025 // set our test theme only present in :/icons 0026 KConfigGroup cg(KSharedConfig::openConfig(), "Icons"); 0027 cg.writeEntry("Theme", "themeinresource"); 0028 cg.sync(); 0029 } 0030 0031 void testConstructor() 0032 { 0033 // At least we test that we don't hit any assert 0034 KIconDialog iconDialog; 0035 } 0036 }; 0037 0038 QTEST_MAIN(KIconDialogTest) 0039 0040 #include "kicondialog_unittest.moc"