[mutter] tests: Check that the crtc gets a logical monitor set



commit f48acd844832703942fe47f7da7d7bed5865e4cf
Author: Jonas Ådahl <jadahl gmail com>
Date:   Tue Dec 13 10:59:53 2016 +0800

    tests: Check that the crtc gets a logical monitor set
    
    https://bugzilla.gnome.org/show_bug.cgi?id=777732

 src/tests/monitor-unit-tests.c |    8 ++++++++
 1 files changed, 8 insertions(+), 0 deletions(-)
---
diff --git a/src/tests/monitor-unit-tests.c b/src/tests/monitor-unit-tests.c
index 54ea615..6a1e6d4 100644
--- a/src/tests/monitor-unit-tests.c
+++ b/src/tests/monitor-unit-tests.c
@@ -256,6 +256,7 @@ check_monitor_configuration (MonitorTestCase *test_case)
       MetaLogicalMonitor *logical_monitor = l->data;
       MonitorTestCaseLogicalMonitor *test_logical_monitor =
         &test_case->expect.logical_monitors[i];
+      int j;
 
       g_assert (logical_monitor->rect.x == test_logical_monitor->layout.x);
       g_assert (logical_monitor->rect.y == test_logical_monitor->layout.y);
@@ -264,6 +265,13 @@ check_monitor_configuration (MonitorTestCase *test_case)
       g_assert (logical_monitor->rect.height ==
                 test_logical_monitor->layout.height);
       g_assert (logical_monitor->scale == test_logical_monitor->scale);
+
+      for (j = 0; j < logical_monitor->n_outputs; j++)
+        {
+          MetaOutput *output = logical_monitor->outputs[j];
+
+          g_assert (output->crtc->logical_monitor == logical_monitor);
+        }
     }
   g_assert (n_logical_monitors == i);
 }


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]