[autotests] Extend test for PlasmaShellSurface::setRole

If the role is set to the same as before it should not emit the changed
signal.
This commit is contained in:
Martin Gräßlin 2016-06-13 16:01:54 +02:00
parent 65b7fd68d2
commit 57148c4bae

View file

@ -206,6 +206,10 @@ void TestPlasmaShell::testRole()
QCOMPARE(roleChangedSpy.count(), 1);
QTEST(sps->role(), "serverRole");
// try changing again should not emit the signal
ps->setRole(clientRole);
QVERIFY(!roleChangedSpy.wait(100));
// set role back to normal
ps->setRole(PlasmaShellSurface::Role::Normal);
QCOMPARE(ps->role(), PlasmaShellSurface::Role::Normal);