Changeset View
Changeset View
Standalone View
Standalone View
autotests/testkwaylandbackend.cpp
Show First 20 Lines • Show All 284 Lines • ▼ Show 20 Line(s) | 272 | { | |||
---|---|---|---|---|---|
285 | auto o = config->outputs().last(); | 285 | auto o = config->outputs().last(); | ||
286 | qCDebug(KSCREEN_WAYLAND) << "Edid: " << o->edid()->isValid(); | 286 | qCDebug(KSCREEN_WAYLAND) << "Edid: " << o->edid()->isValid(); | ||
287 | QVERIFY(o->edid()->isValid()); | 287 | QVERIFY(o->edid()->isValid()); | ||
288 | QCOMPARE(o->edid()->deviceId(), edid->deviceId()); | 288 | QCOMPARE(o->edid()->deviceId(), edid->deviceId()); | ||
289 | QCOMPARE(o->edid()->name(), edid->name()); | 289 | QCOMPARE(o->edid()->name(), edid->name()); | ||
290 | QCOMPARE(o->edid()->vendor(), edid->vendor()); | 290 | QCOMPARE(o->edid()->vendor(), edid->vendor()); | ||
291 | QCOMPARE(o->edid()->eisaId(), edid->eisaId()); | 291 | QCOMPARE(o->edid()->eisaId(), edid->eisaId()); | ||
292 | QCOMPARE(o->edid()->serial(), edid->serial()); | 292 | QCOMPARE(o->edid()->serial(), edid->serial()); | ||
293 | QCOMPARE(o->edid()->hash(), edid->hash()); | 293 | QCOMPARE(o->edid()->hash(), QString::fromLatin1(m_server->outputs().last()->uuid())); | ||
294 | QCOMPARE(o->edid()->width(), edid->width()); | 294 | QCOMPARE(o->edid()->width(), edid->width()); | ||
295 | QCOMPARE(o->edid()->height(), edid->height()); | 295 | QCOMPARE(o->edid()->height(), edid->height()); | ||
296 | QCOMPARE(o->edid()->gamma(), edid->gamma()); | 296 | // Wayland does not support gamma and color correction yet | ||
297 | QCOMPARE(o->edid()->red(), edid->red()); | 297 | //QCOMPARE(o->edid()->gamma(), edid->gamma()); | ||
298 | QCOMPARE(o->edid()->green(), edid->green()); | 298 | //QCOMPARE(o->edid()->red(), edid->red()); | ||
299 | QCOMPARE(o->edid()->blue(), edid->blue()); | 299 | //QCOMPARE(o->edid()->green(), edid->green()); | ||
300 | QCOMPARE(o->edid()->white(), edid->white()); | 300 | //QCOMPARE(o->edid()->blue(), edid->blue()); | ||
301 | //QCOMPARE(o->edid()->white(), edid->white()); | ||||
301 | } | 302 | } | ||
302 | 303 | | |||
303 | void testWaylandBackend::verifyFeatures() | 304 | void testWaylandBackend::verifyFeatures() | ||
304 | { | 305 | { | ||
305 | GetConfigOperation *op = new GetConfigOperation(); | 306 | GetConfigOperation *op = new GetConfigOperation(); | ||
306 | op->exec(); | 307 | op->exec(); | ||
307 | auto config = op->config(); | 308 | auto config = op->config(); | ||
308 | QVERIFY(!config->supportedFeatures().testFlag(Config::Feature::None)); | 309 | QVERIFY(!config->supportedFeatures().testFlag(Config::Feature::None)); | ||
309 | QVERIFY(config->supportedFeatures().testFlag(Config::Feature::Writable)); | 310 | QVERIFY(config->supportedFeatures().testFlag(Config::Feature::Writable)); | ||
310 | QVERIFY(!config->supportedFeatures().testFlag(Config::Feature::PrimaryDisplay)); | 311 | QVERIFY(!config->supportedFeatures().testFlag(Config::Feature::PrimaryDisplay)); | ||
311 | } | 312 | } | ||
312 | 313 | | |||
313 | 314 | | |||
314 | QTEST_GUILESS_MAIN(testWaylandBackend) | 315 | QTEST_GUILESS_MAIN(testWaylandBackend) | ||
315 | 316 | | |||
316 | #include "testkwaylandbackend.moc" | 317 | #include "testkwaylandbackend.moc" |