Switch lockscreen test to OpenGL
Summary: Main reason for using QPainter was the fact that build.kde.org did not support OpenGL back when the test got introduced. As we have vgem support nowadays we can switch back to OpenGL. Test Plan: 100% tests passed, 0 tests failed out of 130, but the test is flaky with and without this change Reviewers: #kwin Subscribers: kwin Tags: #kwin Differential Revision: https://phabricator.kde.org/D16940
This commit is contained in:
parent
98ddb93dfe
commit
f8459a71cc
1 changed files with 4 additions and 1 deletions
|
@ -182,6 +182,9 @@ AbstractClient *LockScreenTest::showWindow()
|
|||
|
||||
void LockScreenTest::initTestCase()
|
||||
{
|
||||
if (!QFile::exists(QStringLiteral("/dev/dri/card0"))) {
|
||||
QSKIP("Needs a dri device");
|
||||
}
|
||||
qRegisterMetaType<KWin::ShellClient*>();
|
||||
qRegisterMetaType<KWin::AbstractClient*>();
|
||||
QSignalSpy workspaceCreatedSpy(kwinApp(), &Application::workspaceCreated);
|
||||
|
@ -190,13 +193,13 @@ void LockScreenTest::initTestCase()
|
|||
QMetaObject::invokeMethod(kwinApp()->platform(), "setVirtualOutputs", Qt::DirectConnection, Q_ARG(int, 2));
|
||||
QVERIFY(waylandServer()->init(s_socketName.toLocal8Bit()));
|
||||
|
||||
qputenv("KWIN_COMPOSE", QByteArrayLiteral("O2"));
|
||||
kwinApp()->start();
|
||||
QVERIFY(workspaceCreatedSpy.wait());
|
||||
QCOMPARE(screens()->count(), 2);
|
||||
QCOMPARE(screens()->geometry(0), QRect(0, 0, 1280, 1024));
|
||||
QCOMPARE(screens()->geometry(1), QRect(1280, 0, 1280, 1024));
|
||||
setenv("QT_QPA_PLATFORM", "wayland", true);
|
||||
setenv("QMLSCENE_DEVICE", "softwarecontext", true);
|
||||
waylandServer()->initWorkspace();
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue