File indexing completed on 2025-01-19 04:46:39

0001 /*
0002    SPDX-FileCopyrightText: 2016-2024 Laurent Montel <montel@kde.org>
0003 
0004    SPDX-License-Identifier: GPL-2.0-or-later
0005 */
0006 
0007 #include "autocorrectionplugineditorinterfacetest.h"
0008 #include "../autocorrectionplugineditorinterface.h"
0009 #include <KActionCollection>
0010 #include <QTest>
0011 
0012 AutoCorrectionPluginEditorInterfaceTest::AutoCorrectionPluginEditorInterfaceTest(QObject *parent)
0013     : QObject(parent)
0014 {
0015 }
0016 
0017 AutoCorrectionPluginEditorInterfaceTest::~AutoCorrectionPluginEditorInterfaceTest() = default;
0018 
0019 void AutoCorrectionPluginEditorInterfaceTest::shouldHaveDefaultValue()
0020 {
0021     AutoCorrectionPluginEditorInterface interface(nullptr);
0022     interface.createAction(new KActionCollection(this));
0023     MessageComposer::PluginActionType type = interface.actionType();
0024     QVERIFY(type.action());
0025     QCOMPARE(type.type(), MessageComposer::PluginActionType::Tools);
0026 }
0027 
0028 QTEST_MAIN(AutoCorrectionPluginEditorInterfaceTest)
0029 
0030 #include "moc_autocorrectionplugineditorinterfacetest.cpp"