From a90daf82b6a836eb4c579ff4752900cffc63aa3e Mon Sep 17 00:00:00 2001 From: Elvis Angelaccio Date: Sat, 3 Feb 2018 22:34:24 +0100 Subject: [PATCH] Fix -Wunused-result warnings --- src/tests/dolphinmainwindowtest.cpp | 2 +- src/tests/kfileitemlistviewtest.cpp | 2 +- src/tests/kitemlistcontrollertest.cpp | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/tests/dolphinmainwindowtest.cpp b/src/tests/dolphinmainwindowtest.cpp index be86c5016f..26036c9afa 100644 --- a/src/tests/dolphinmainwindowtest.cpp +++ b/src/tests/dolphinmainwindowtest.cpp @@ -47,7 +47,7 @@ void DolphinMainWindowTest::testClosingTabsWithSearchBoxVisible() m_mainWindow->openDirectories({ QUrl::fromLocalFile(QDir::homePath()) }, false); m_mainWindow->show(); // Without this call the searchbox doesn't get FocusIn events. - QTest::qWaitForWindowExposed(m_mainWindow.data()); + QVERIFY(QTest::qWaitForWindowExposed(m_mainWindow.data())); QVERIFY(m_mainWindow->isVisible()); auto tabWidget = m_mainWindow->findChild("tabWidget"); diff --git a/src/tests/kfileitemlistviewtest.cpp b/src/tests/kfileitemlistviewtest.cpp index b4b5813840..775602f9f8 100644 --- a/src/tests/kfileitemlistviewtest.cpp +++ b/src/tests/kfileitemlistviewtest.cpp @@ -56,7 +56,7 @@ void KFileItemListViewTest::init() m_graphicsView = new QGraphicsView(); m_graphicsView->show(); - QTest::qWaitForWindowExposed(m_graphicsView); + QVERIFY(QTest::qWaitForWindowExposed(m_graphicsView)); } void KFileItemListViewTest::cleanup() diff --git a/src/tests/kitemlistcontrollertest.cpp b/src/tests/kitemlistcontrollertest.cpp index 79455844aa..a468ca6dc6 100644 --- a/src/tests/kitemlistcontrollertest.cpp +++ b/src/tests/kitemlistcontrollertest.cpp @@ -143,7 +143,7 @@ void KItemListControllerTest::initTestCase() QVERIFY(spyDirectoryLoadingCompleted.wait()); m_container->show(); - QTest::qWaitForWindowExposed(m_container); + QVERIFY(QTest::qWaitForWindowExposed(m_container)); } void KItemListControllerTest::cleanupTestCase()