From 64890b210c51b673a46152dbfcf4f24349471b3e Mon Sep 17 00:00:00 2001 From: Lukas Ruzicka Date: Mon, 7 Mar 2022 14:37:25 +0100 Subject: [PATCH] Add test for tab. --- .../applications/system-settings/aaa_setup.pm | 5 ++- .../system-settings/appearance.pm | 38 +++++++++++++++++++ tests/applications/system-settings/network.pm | 22 +++++++++++ 3 files changed, 63 insertions(+), 2 deletions(-) create mode 100644 tests/applications/system-settings/appearance.pm create mode 100644 tests/applications/system-settings/network.pm diff --git a/tests/applications/system-settings/aaa_setup.pm b/tests/applications/system-settings/aaa_setup.pm index 04fc2fb8..f9d9a449 100644 --- a/tests/applications/system-settings/aaa_setup.pm +++ b/tests/applications/system-settings/aaa_setup.pm @@ -13,11 +13,12 @@ sub run { # Start the application menu_launch_type("settings"); - # Check that is started - assert_screen 'apps_run_settings'; # Fullsize the Settings window. send_key("super-up"); + + # Check that is started + assert_screen 'apps_run_settings'; } diff --git a/tests/applications/system-settings/appearance.pm b/tests/applications/system-settings/appearance.pm new file mode 100644 index 00000000..df712863 --- /dev/null +++ b/tests/applications/system-settings/appearance.pm @@ -0,0 +1,38 @@ +use base "installedtest"; +use strict; +use testapi; +use utils; + +# This is to check up the Appearance tab. + +sub run { + my $self = shift; + + assert_and_click("settings_menu_appearance"); + + # Change style to Dark + assert_and_click("settings_appearance_set_darkmode"); + + # Check that the application uses now Darkmode + assert_screen("settings_appearance_darkmode_on"); + + # Change background + assert_and_click("settings_appearance_set_background"); + + # Switch off the application. + send_key("alt-f4"); + + # Check that the background is correctly changed. + assert_screen("settings_alternate_background_set"); + + + +} + +sub test_flags { + return {fatal => 1, always_rollback => 1}; +} + +1; + +# vim: set sw=4 et: diff --git a/tests/applications/system-settings/network.pm b/tests/applications/system-settings/network.pm new file mode 100644 index 00000000..67e16884 --- /dev/null +++ b/tests/applications/system-settings/network.pm @@ -0,0 +1,22 @@ +use base "installedtest"; +use strict; +use testapi; +use utils; + +# This is to check up the Network tab. + +sub run { + my $self = shift; + + assert_and_click("settings_menu_network"); + assert_screen("settings_network_wired_connected"); + +} + +sub test_flags { + return {fatal => 1, milestone => 1}; +} + +1; + +# vim: set sw=4 et: