diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt index eb51d202d..72c08b976 100644 --- a/tests/CMakeLists.txt +++ b/tests/CMakeLists.txt @@ -22,10 +22,12 @@ set(WIDGET_TEST #testcases/widgets/ut_danchors.cpp testcases/widgets/ut_darrowbutton.cpp testcases/widgets/ut_darrowlinedrawer.cpp - testcases/widgets/ut_darrowlineexpand.cpp + # TODO: Qt6 no longer support + #testcases/widgets/ut_darrowlineexpand.cpp testcases/widgets/ut_darrowrectangle.cpp testcases/widgets/ut_dbackgroundgroup.cpp - testcases/widgets/ut_dbaseexpand.cpp + # TODO: Qt6 no longer support + #testcases/widgets/ut_dbaseexpand.cpp testcases/widgets/ut_dbaseline.cpp testcases/widgets/ut_dblureffectwidget.cpp testcases/widgets/ut_dboxwidget.cpp diff --git a/tests/testcases/widgets/ut_daboutdialog.cpp b/tests/testcases/widgets/ut_daboutdialog.cpp index 6d48f4afb..d10c7ac3d 100644 --- a/tests/testcases/widgets/ut_daboutdialog.cpp +++ b/tests/testcases/widgets/ut_daboutdialog.cpp @@ -23,10 +23,12 @@ class ut_DAboutDialog : public testing::Test DAboutDialog *widget = nullptr; }; +#if DTK_VERSION < DTK_VERSION_CHECK(6, 0, 0, 0) // dtk 6.0 no longer support TEST_F(ut_DAboutDialog, setAcknowledgementLink) { widget->setAcknowledgementLink(QString{"setAcknowledgementLink"}); }; +#endif TEST_F(ut_DAboutDialog, setAcknowledgementVisible) { @@ -89,4 +91,3 @@ TEST_F(ut_DAboutDialog, setWindowTitle) widget->setWindowTitle("setWindowTitle"); ASSERT_EQ(widget->windowTitle(), "setWindowTitle"); }; - diff --git a/tests/testcases/widgets/ut_darrowlinedrawer.cpp b/tests/testcases/widgets/ut_darrowlinedrawer.cpp index ea2c96f1a..d0fa17111 100644 --- a/tests/testcases/widgets/ut_darrowlinedrawer.cpp +++ b/tests/testcases/widgets/ut_darrowlinedrawer.cpp @@ -53,6 +53,8 @@ TEST_F(ut_DArrowLineDrawer, testDArrowLineDrawerSetExpand) // TODO } + +#if DTK_VERSION < DTK_VERSION_CHECK(6, 0, 0, 0) // dtk 6.0 no longer support TEST_F(ut_DArrowLineDrawer, testHeaderLineAndResizeEvent) { DBaseLine *headerLine = drawer->headerLine(); @@ -76,3 +78,4 @@ TEST_F(ut_DArrowLineDrawer, testHeaderLineAndResizeEvent) ASSERT_TRUE(QTest::qWaitFor([&] { return (drawer->width() == (originWidth + LoopCount)); })); } +#endif diff --git a/tests/testcases/widgets/ut_dstyleoption.cpp b/tests/testcases/widgets/ut_dstyleoption.cpp index e26934304..6ac17afbf 100644 --- a/tests/testcases/widgets/ut_dstyleoption.cpp +++ b/tests/testcases/widgets/ut_dstyleoption.cpp @@ -5,6 +5,7 @@ #include #include #include +#include #include "dstyleoption.h" DWIDGET_USE_NAMESPACE @@ -116,7 +117,7 @@ TEST_F(ut_DStyleOptionBackgroundGroup, init) { QWidget *widget = new QWidget(); target->init(widget); - ASSERT_EQ(target->palette, DApplicationHelper::instance()->palette(widget)); + ASSERT_EQ(target->palette, DPaletteHelper::instance()->palette(widget)); widget->deleteLater(); };