File indexing completed on 2024-12-22 04:46:00
0001 /* 0002 SPDX-FileCopyrightText: 2022-2024 Laurent Montel <montel@kde.org> 0003 0004 SPDX-License-Identifier: LGPL-2.0-or-later 0005 */ 0006 0007 #include "myaccountpersonalaccesscreatedialogtest.h" 0008 #include "myaccount/myaccountpersonalaccesscreatedialog.h" 0009 #include "myaccount/myaccountpersonalaccesscreatewidget.h" 0010 #include <QDialogButtonBox> 0011 #include <QTest> 0012 #include <QVBoxLayout> 0013 QTEST_MAIN(MyAccountPersonalAccessCreateDialogTest) 0014 0015 MyAccountPersonalAccessCreateDialogTest::MyAccountPersonalAccessCreateDialogTest(QObject *parent) 0016 : QObject{parent} 0017 { 0018 } 0019 0020 void MyAccountPersonalAccessCreateDialogTest::shouldHaveDefaultValues() 0021 { 0022 MyAccountPersonalAccessCreateDialog d; 0023 QVERIFY(!d.windowTitle().isEmpty()); 0024 0025 auto mainLayout = d.findChild<QVBoxLayout *>(QStringLiteral("mainLayout")); 0026 QVERIFY(mainLayout); 0027 0028 auto mCreateWidget = d.findChild<MyAccountPersonalAccessCreateWidget *>(QStringLiteral("mCreateWidget")); 0029 QVERIFY(mCreateWidget); 0030 0031 auto button = d.findChild<QDialogButtonBox *>(QStringLiteral("button")); 0032 QVERIFY(button); 0033 } 0034 0035 #include "moc_myaccountpersonalaccesscreatedialogtest.cpp"