From 6c0f107db06cb6e6c7586d9a87bd02a8f67ebb3f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonas=20=C3=85dahl?= Date: Fri, 11 Aug 2017 10:40:04 +0800 Subject: [PATCH] tests: Add rotated multi head monitor config migration test https://bugzilla.gnome.org/show_bug.cgi?id=777732 --- src/tests/migration/first-rotated-new.xml | 44 +++++++++++++++++++ src/tests/migration/first-rotated-old.xml | 37 ++++++++++++++++ .../monitor-config-migration-unit-tests.c | 8 ++++ 3 files changed, 89 insertions(+) create mode 100644 src/tests/migration/first-rotated-new.xml create mode 100644 src/tests/migration/first-rotated-old.xml diff --git a/src/tests/migration/first-rotated-new.xml b/src/tests/migration/first-rotated-new.xml new file mode 100644 index 000000000..9f875c21f --- /dev/null +++ b/src/tests/migration/first-rotated-new.xml @@ -0,0 +1,44 @@ + + + + + 0 + 0 + + left + no + + + + HDMI-1 + DEL + DELL P2415Q + GTTPW67P0WFB + + + 3840 + 2160 + 29.981103897094727 + + + + + 2160 + 0 + yes + + + eDP-1 + AUO + 0x123d + 0x00000000 + + + 1920 + 1080 + 60.049972534179688 + + + + + diff --git a/src/tests/migration/first-rotated-old.xml b/src/tests/migration/first-rotated-old.xml new file mode 100644 index 000000000..b00a35963 --- /dev/null +++ b/src/tests/migration/first-rotated-old.xml @@ -0,0 +1,37 @@ + + + no + + DEL + DELL P2415Q + GTTPW67P0WFB + 2160 + 3840 + 29.981103897094727 + 0 + 0 + left + no + no + no + no + no + + + AUO + 0x123d + 0x00000000 + 1920 + 1080 + 60.049972534179688 + 2160 + 0 + normal + no + no + yes + no + no + + + diff --git a/src/tests/monitor-config-migration-unit-tests.c b/src/tests/monitor-config-migration-unit-tests.c index 08d788c31..15c27b347 100644 --- a/src/tests/monitor-config-migration-unit-tests.c +++ b/src/tests/monitor-config-migration-unit-tests.c @@ -100,6 +100,12 @@ meta_test_monitor_config_migration_tiled (void) 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 init_monitor_config_migration_tests (void) { @@ -109,4 +115,6 @@ init_monitor_config_migration_tests (void) meta_test_monitor_config_migration_rotated); g_test_add_func ("/backends/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); }