1
0
Fork 0

tests: Add rotated multi head monitor config migration test

https://bugzilla.gnome.org/show_bug.cgi?id=777732
This commit is contained in:
Jonas Ådahl 2017-08-11 10:40:04 +08:00
parent 61950755ec
commit 6c0f107db0
3 changed files with 89 additions and 0 deletions

View file

@ -0,0 +1,44 @@
<monitors version="2">
<configuration>
<migrated/>
<logicalmonitor>
<x>0</x>
<y>0</y>
<transform>
<rotation>left</rotation>
<flipped>no</flipped>
</transform>
<monitor>
<monitorspec>
<connector>HDMI-1</connector>
<vendor>DEL</vendor>
<product>DELL P2415Q</product>
<serial>GTTPW67P0WFB</serial>
</monitorspec>
<mode>
<width>3840</width>
<height>2160</height>
<rate>29.981103897094727</rate>
</mode>
</monitor>
</logicalmonitor>
<logicalmonitor>
<x>2160</x>
<y>0</y>
<primary>yes</primary>
<monitor>
<monitorspec>
<connector>eDP-1</connector>
<vendor>AUO</vendor>
<product>0x123d</product>
<serial>0x00000000</serial>
</monitorspec>
<mode>
<width>1920</width>
<height>1080</height>
<rate>60.049972534179688</rate>
</mode>
</monitor>
</logicalmonitor>
</configuration>
</monitors>

View file

@ -0,0 +1,37 @@
<monitors version="1">
<configuration>
<clone>no</clone>
<output name="HDMI-1">
<vendor>DEL</vendor>
<product>DELL P2415Q</product>
<serial>GTTPW67P0WFB</serial>
<width>2160</width>
<height>3840</height>
<rate>29.981103897094727</rate>
<x>0</x>
<y>0</y>
<rotation>left</rotation>
<reflect_x>no</reflect_x>
<reflect_y>no</reflect_y>
<primary>no</primary>
<presentation>no</presentation>
<underscanning>no</underscanning>
</output>
<output name="eDP-1">
<vendor>AUO</vendor>
<product>0x123d</product>
<serial>0x00000000</serial>
<width>1920</width>
<height>1080</height>
<rate>60.049972534179688</rate>
<x>2160</x>
<y>0</y>
<rotation>normal</rotation>
<reflect_x>no</reflect_x>
<reflect_y>no</reflect_y>
<primary>yes</primary>
<presentation>no</presentation>
<underscanning>no</underscanning>
</output>
</configuration>
</monitors>

View file

@ -100,6 +100,12 @@ meta_test_monitor_config_migration_tiled (void)
test_migration ("tiled-old.xml", "tiled-new.xml"); test_migration ("tiled-old.xml", "tiled-new.xml");
} }
static void
meta_test_monitor_config_migration_first_rotated (void)
{
test_migration ("first-rotated-old.xml", "first-rotated-new.xml");
}
void void
init_monitor_config_migration_tests (void) init_monitor_config_migration_tests (void)
{ {
@ -109,4 +115,6 @@ init_monitor_config_migration_tests (void)
meta_test_monitor_config_migration_rotated); meta_test_monitor_config_migration_rotated);
g_test_add_func ("/backends/monitor-config-migration/tiled", g_test_add_func ("/backends/monitor-config-migration/tiled",
meta_test_monitor_config_migration_tiled); meta_test_monitor_config_migration_tiled);
g_test_add_func ("/backends/monitor-config-migration/first-rotated",
meta_test_monitor_config_migration_first_rotated);
} }