File indexing completed on 2024-05-12 16:45:26
0001 /*************************************************************************** 0002 * SPDX-FileCopyrightText: 2022 S. MANKOWSKI stephane@mankowski.fr 0003 * SPDX-FileCopyrightText: 2022 G. DE BURE support@mankowski.fr 0004 * SPDX-License-Identifier: GPL-3.0-or-later 0005 ***************************************************************************/ 0006 /** @file 0007 * This file is a test for SKGDateEdit component. 0008 * 0009 * @author Stephane MANKOWSKI / Guillaume DE BURE 0010 */ 0011 #include "skgtestcolorbutton.h" 0012 #include "skgcolorbutton.h" 0013 0014 void SKGTESTColorButton::Test() 0015 { 0016 SKGColorButton color(nullptr); 0017 color.setText(QStringLiteral("Hello")); 0018 QCOMPARE(color.text(), QStringLiteral("Hello")); 0019 color.setColor(Qt::white); 0020 QCOMPARE(color.color(), QColor(Qt::white)); 0021 color.setDefaultColor(Qt::black); 0022 QCOMPARE(color.defaultColor(), QColor(Qt::black)); 0023 } 0024 0025 QTEST_MAIN(SKGTESTColorButton) 0026