autotests: Fix TestDBusInterface

x11DesktopNumber property was replaced with the desktops property, which
is a list of desktop ids.
This commit is contained in:
Vlad Zahorodnii 2021-09-30 10:28:31 +03:00
parent bcbba62c7c
commit 721bfe1740

View file

@ -126,7 +126,7 @@ void TestDbusInterface::testGetWindowInfoXdgShellClient()
QCOMPARE(windowData.value(QStringLiteral("y")).toInt(), client->y()); QCOMPARE(windowData.value(QStringLiteral("y")).toInt(), client->y());
QCOMPARE(windowData.value(QStringLiteral("width")).toInt(), client->width()); QCOMPARE(windowData.value(QStringLiteral("width")).toInt(), client->width());
QCOMPARE(windowData.value(QStringLiteral("height")).toInt(), client->height()); QCOMPARE(windowData.value(QStringLiteral("height")).toInt(), client->height());
QCOMPARE(windowData.value(QStringLiteral("x11DesktopNumber")).toInt(), 1); QCOMPARE(windowData.value(QStringLiteral("desktops")).toStringList(), client->desktopIds());
QCOMPARE(windowData.value(QStringLiteral("minimized")).toBool(), false); QCOMPARE(windowData.value(QStringLiteral("minimized")).toBool(), false);
QCOMPARE(windowData.value(QStringLiteral("shaded")).toBool(), false); QCOMPARE(windowData.value(QStringLiteral("shaded")).toBool(), false);
QCOMPARE(windowData.value(QStringLiteral("fullscreen")).toBool(), false); QCOMPARE(windowData.value(QStringLiteral("fullscreen")).toBool(), false);
@ -191,7 +191,7 @@ void TestDbusInterface::testGetWindowInfoXdgShellClient()
QCOMPARE(client->desktop(), 2); QCOMPARE(client->desktop(), 2);
reply = getWindowInfo(client->internalId()); reply = getWindowInfo(client->internalId());
reply.waitForFinished(); reply.waitForFinished();
QCOMPARE(reply.value().value(QStringLiteral("x11DesktopNumber")).toInt(), 2); QCOMPARE(reply.value().value(QStringLiteral("desktops")).toStringList(), client->desktopIds());
client->move(QPoint(10, 20)); client->move(QPoint(10, 20));
reply = getWindowInfo(client->internalId()); reply = getWindowInfo(client->internalId());
@ -269,7 +269,7 @@ void TestDbusInterface::testGetWindowInfoX11Client()
QCOMPARE(windowData.value(QStringLiteral("y")).toInt(), client->y()); QCOMPARE(windowData.value(QStringLiteral("y")).toInt(), client->y());
QCOMPARE(windowData.value(QStringLiteral("width")).toInt(), client->width()); QCOMPARE(windowData.value(QStringLiteral("width")).toInt(), client->width());
QCOMPARE(windowData.value(QStringLiteral("height")).toInt(), client->height()); QCOMPARE(windowData.value(QStringLiteral("height")).toInt(), client->height());
QCOMPARE(windowData.value(QStringLiteral("x11DesktopNumber")).toInt(), 1); QCOMPARE(windowData.value(QStringLiteral("desktops")).toStringList(), client->desktopIds());
QCOMPARE(windowData.value(QStringLiteral("minimized")).toBool(), false); QCOMPARE(windowData.value(QStringLiteral("minimized")).toBool(), false);
QCOMPARE(windowData.value(QStringLiteral("shaded")).toBool(), false); QCOMPARE(windowData.value(QStringLiteral("shaded")).toBool(), false);
QCOMPARE(windowData.value(QStringLiteral("fullscreen")).toBool(), false); QCOMPARE(windowData.value(QStringLiteral("fullscreen")).toBool(), false);