Commit 31a434b6 authored by Martin Flöser's avatar Martin Flöser
Browse files

[autotest] Try making IdleTest more robust

It started to fail on build.kde.org with a segfault. While I cannot
reproduce this locally it looks like client objects survive to the next
test and thus cause issues.

This change attempts to reduce the risk by making sure that everything
is cleaned up correctly. If that fixes the issue we can look into a
proper fix.
parent 618bebb6
......@@ -152,6 +152,10 @@ void IdleTest::testTimeout()
QVERIFY(resumedFormIdleSpy.isEmpty());
m_seatInterface->setTimestamp(1);
QVERIFY(resumedFormIdleSpy.wait());
timeout.reset();
m_connection->flush();
m_display->dispatchEvents();
}
void IdleTest::testSimulateUserActivity()
......@@ -176,6 +180,10 @@ void IdleTest::testSimulateUserActivity()
QVERIFY(resumedFormIdleSpy.isEmpty());
timeout->simulateUserActivity();
QVERIFY(resumedFormIdleSpy.wait());
timeout.reset();
m_connection->flush();
m_display->dispatchEvents();
}
QTEST_GUILESS_MAIN(IdleTest)
......
Supports Markdown
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