File indexing completed on 2024-06-09 04:59:04
0001 /* 0002 SPDX-FileCopyrightText: 2023-2024 Laurent Montel <montel.org> 0003 0004 SPDX-License-Identifier: LGPL-2.0-or-later 0005 */ 0006 0007 #include "channelrolesinfowidgettest.h" 0008 #include "dialogs/channelrolesinfowidget.h" 0009 #include <QFormLayout> 0010 #include <QGroupBox> 0011 #include <QTest> 0012 QTEST_MAIN(ChannelRolesInfoWidgetTest) 0013 0014 ChannelRolesInfoWidgetTest::ChannelRolesInfoWidgetTest(QObject *parent) 0015 : QObject{parent} 0016 { 0017 } 0018 0019 void ChannelRolesInfoWidgetTest::shouldHaveDefaultValues() 0020 { 0021 ChannelRolesInfoWidget w; 0022 auto mainLayout = w.findChild<QHBoxLayout *>(QStringLiteral("mainLayout")); 0023 QVERIFY(mainLayout); 0024 QCOMPARE(mainLayout->contentsMargins(), QMargins{}); 0025 0026 auto box = w.findChild<QGroupBox *>(QStringLiteral("box")); 0027 QVERIFY(box); 0028 QVERIFY(!box->title().isEmpty()); 0029 0030 auto mFormLayout = w.findChild<QFormLayout *>(QStringLiteral("mFormLayout")); 0031 QVERIFY(mFormLayout); 0032 } 0033 0034 #include "moc_channelrolesinfowidgettest.cpp"