diff --git a/src/tests/self-test/SelfTest.cpp b/src/tests/self-test/SelfTest.cpp index f8e23b8c2..4c0a02647 100644 --- a/src/tests/self-test/SelfTest.cpp +++ b/src/tests/self-test/SelfTest.cpp @@ -23,6 +23,7 @@ #include #include +#include "../../app/App.hpp" #include "../../components/core/CoreManager.hpp" #include "../TestUtils.hpp" @@ -36,8 +37,8 @@ void SelfTest::checkAppStartup () { QVERIFY(spyCoreStarted.wait(5000)); - if (spyLoaderReady.count() == 1) - return; + if (spyLoaderReady.count() != 1) + QVERIFY(spyLoaderReady.wait(1000)); - QVERIFY(spyLoaderReady.wait(1000)); + QVERIFY(QTest::qWaitForWindowExposed(App::getInstance()->getMainWindow())); }