diff --git a/autotests/annotationtoolbartest.cpp b/autotests/annotationtoolbartest.cpp index e47c7d2ee..1bcb2ff3c 100644 --- a/autotests/annotationtoolbartest.cpp +++ b/autotests/annotationtoolbartest.cpp @@ -244,6 +244,7 @@ void AnnotationToolBarTest::testAnnotationToolBarActionsEnabledState() QVERIFY(part); KActionCollection *ac = part->actionCollection(); + QAction *aQuickTools = ac->action(QStringLiteral("annotation_favorites")); QAction *aHighlighter = ac->action(QStringLiteral("annotation_highlighter")); QAction *aUnderline = ac->action(QStringLiteral("annotation_underline")); QAction *aSquiggle = ac->action(QStringLiteral("annotation_squiggle")); @@ -255,6 +256,7 @@ void AnnotationToolBarTest::testAnnotationToolBarActionsEnabledState() QAction *aGeomShapes = ac->action(QStringLiteral("annotation_geometrical_shape")); QAction *aStamp = ac->action(QStringLiteral("annotation_stamp")); + QFETCH(bool, aQuickToolsEnabled); QFETCH(bool, aHighlighterEnabled); QFETCH(bool, aUnderlineEnabled); QFETCH(bool, aSquiggleEnabled); @@ -266,6 +268,7 @@ void AnnotationToolBarTest::testAnnotationToolBarActionsEnabledState() QFETCH(bool, aGeomShapesEnabled); QFETCH(bool, aStampEnabled); + QCOMPARE(aQuickTools->isEnabled(), aQuickToolsEnabled); QCOMPARE(aHighlighter->isEnabled(), aHighlighterEnabled); QCOMPARE(aUnderline->isEnabled(), aUnderlineEnabled); QCOMPARE(aSquiggle->isEnabled(), aSquiggleEnabled); @@ -281,6 +284,7 @@ void AnnotationToolBarTest::testAnnotationToolBarActionsEnabledState() void AnnotationToolBarTest::testAnnotationToolBarActionsEnabledState_data() { QTest::addColumn("document"); + QTest::addColumn("aQuickToolsEnabled"); QTest::addColumn("aHighlighterEnabled"); QTest::addColumn("aUnderlineEnabled"); QTest::addColumn("aSquiggleEnabled"); @@ -292,9 +296,9 @@ void AnnotationToolBarTest::testAnnotationToolBarActionsEnabledState_data() QTest::addColumn("aGeomShapesEnabled"); QTest::addColumn("aStampEnabled"); - QTest::addRow("pdf") << QStringLiteral(KDESRCDIR "data/file1.pdf") << true << true << true << true << true << true << true << true << true << true; - QTest::addRow("protected-pdf") << QStringLiteral(KDESRCDIR "data/protected.pdf") << false << false << false << false << false << false << false << false << false << false; - QTest::addRow("image") << QStringLiteral(KDESRCDIR "data/potato.jpg") << false << false << false << false << true << true << true << true << true << true; + QTest::addRow("pdf") << QStringLiteral(KDESRCDIR "data/file1.pdf") << true << true << true << true << true << true << true << true << true << true << true; + QTest::addRow("protected-pdf") << QStringLiteral(KDESRCDIR "data/protected.pdf") << false << false << false << false << false << false << false << false << false << false << false; + QTest::addRow("image") << QStringLiteral(KDESRCDIR "data/potato.jpg") << true << false << false << false << false << true << true << true << true << true << true; } void AnnotationToolBarTest::testAnnotationToolBarConfigActionsEnabledState()