[autotests] Try to make TestWindowManagement more robust

The test started to segfault on build.kde.org. It looks like an event
survives the destruction of the server. Thus this change tries to
dispatchEvents once more before destroying everything.
This commit is contained in:
Martin Gräßlin 2016-08-22 15:57:25 +02:00
parent 31a434b633
commit 34eb146db7

View file

@ -226,6 +226,7 @@ void TestWindowManagement::cleanup()
}
if (m_thread) {
if (m_connection) {
m_connection->flush();
m_connection->deleteLater();
}
m_thread->quit();
@ -235,6 +236,7 @@ void TestWindowManagement::cleanup()
}
m_connection = nullptr;
m_display->dispatchEvents();
delete m_windowManagementInterface;
m_windowManagementInterface = nullptr;