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

0001 /*
0002    SPDX-FileCopyrightText: 2019-2024 Laurent Montel <montel@kde.org>
0003 
0004    SPDX-License-Identifier: LGPL-2.0-or-later
0005 */
0006 
0007 #include "dkimkeyrecordwidgettest.h"
0008 #include "dkimkeyrecordwidget.h"
0009 #include <MessageViewer/DKIMManagerKeyWidget>
0010 #include <QHBoxLayout>
0011 #include <QStandardPaths>
0012 #include <QTest>
0013 QTEST_MAIN(DKIMKeyRecordWidgetTest)
0014 
0015 DKIMKeyRecordWidgetTest::DKIMKeyRecordWidgetTest(QObject *parent)
0016     : QObject(parent)
0017 {
0018     QStandardPaths::setTestModeEnabled(true);
0019 }
0020 
0021 void DKIMKeyRecordWidgetTest::shouldHaveDefaultValues()
0022 {
0023     DKIMKeyRecordWidget w;
0024     auto mainLayout = w.findChild<QHBoxLayout *>(QStringLiteral("mainLayout"));
0025     QVERIFY(mainLayout);
0026 
0027     auto mManagerKeyWidget = w.findChild<MessageViewer::DKIMManagerKeyWidget *>(QStringLiteral("mManagerKeyWidget"));
0028     QVERIFY(mManagerKeyWidget);
0029 }
0030 
0031 #include "moc_dkimkeyrecordwidgettest.cpp"