Commit d63438fc authored by Sandro Knauß's avatar Sandro Knauß

make viewertest pass again

parent c2e4c852
...@@ -31,41 +31,24 @@ void ViewerTest::shouldHaveDefaultValuesOnCreation() ...@@ -31,41 +31,24 @@ void ViewerTest::shouldHaveDefaultValuesOnCreation()
viewer.show(); viewer.show();
QTest::qWaitForWindowExposed(&viewer); QTest::qWaitForWindowExposed(&viewer);
QVERIFY(!viewer.message()); QWidget *mViewer = viewer.findChild<QWidget *>(QStringLiteral("mViewer"));
QWidget *createtodowidget = viewer.findChild<QWidget *>(QStringLiteral("todoedit")); QVERIFY(mViewer);
QVERIFY(createtodowidget); QCOMPARE(mViewer->isVisible(), true);
QCOMPARE(createtodowidget->isVisible(), false);
QWidget *sliderContainer = viewer.findChild<QWidget *>(QStringLiteral("slidercontainer")); QWidget *sliderContainer = viewer.findChild<QWidget *>(QStringLiteral("slidercontainer"));
QVERIFY(sliderContainer); QVERIFY(sliderContainer);
QVERIFY(sliderContainer->isVisible()); QCOMPARE(sliderContainer->isVisible(), false);
QWidget *translaterwidget = viewer.findChild<QWidget *>(QStringLiteral("translatorwidget"));
QVERIFY(translaterwidget);
QVERIFY(!translaterwidget->isVisible());
QWidget *colorBar = viewer.findChild<QWidget *>(QStringLiteral("mColorBar")); QWidget *colorBar = viewer.findChild<QWidget *>(QStringLiteral("mColorBar"));
QVERIFY(colorBar); QVERIFY(colorBar);
QWidget *scandetectionWidget = viewer.findChild<QWidget *>(QStringLiteral("scandetectionwarning")); QWidget *scandetectionWidget = viewer.findChild<QWidget *>(QStringLiteral("scandetectionwarning"));
QVERIFY(scandetectionWidget); QVERIFY(scandetectionWidget);
QVERIFY(!scandetectionWidget->isVisible()); QCOMPARE(scandetectionWidget->isVisible(), false);
QWidget *openattachementfolderwidget = viewer.findChild<QWidget *>(QStringLiteral("openattachementfolderwidget")); QWidget *openattachementfolderwidget = viewer.findChild<QWidget *>(QStringLiteral("openattachementfolderwidget"));
QVERIFY(openattachementfolderwidget); QVERIFY(openattachementfolderwidget);
QVERIFY(!openattachementfolderwidget->isVisible()); QCOMPARE(openattachementfolderwidget->isVisible(), false);
QWidget *createeventwidget = viewer.findChild<QWidget *>(QStringLiteral("eventedit"));
QVERIFY(createeventwidget);
QCOMPARE(createeventwidget->isVisible(), false);
QWidget *createnotewidget = viewer.findChild<QWidget *>(QStringLiteral("noteedit"));
QVERIFY(createnotewidget);
QCOMPARE(createnotewidget->isVisible(), false);
QWidget *mViewer = viewer.findChild<QWidget *>(QStringLiteral("mViewer"));
QVERIFY(mViewer);
QCOMPARE(mViewer->isVisible(), true);
QVERIFY(viewer.toggleFixFontAction()); QVERIFY(viewer.toggleFixFontAction());
QVERIFY(viewer.toggleMimePartTreeAction()); QVERIFY(viewer.toggleMimePartTreeAction());
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment