#275 Create the test for system monitor.
Merged 2 years ago by adamwill. Opened 2 years ago by lruzicka.

@@ -0,0 +1,15 @@ 

+ {

+   "properties": [],

+   "tags": [

+     "sysmon_about_shown"

+   ],

+   "area": [

+     {

+       "xpos": 443,

+       "ypos": 287,

+       "width": 133,

+       "height": 132,

+       "type": "match"

+     }

+   ]

+ } 

\ No newline at end of file

empty or binary file added
@@ -0,0 +1,15 @@ 

+ {

+   "properties": [],

+   "tags": [

+     "sysmon_credits_shown"

+   ],

+   "area": [

+     {

+       "xpos": 423,

+       "ypos": 428,

+       "width": 176,

+       "height": 23,

+       "type": "match"

+     }

+   ]

+ } 

\ No newline at end of file

empty or binary file added
@@ -0,0 +1,15 @@ 

+ {

+   "area": [

+     {

+       "xpos": 1,

+       "height": 53,

+       "ypos": 136,

+       "type": "match",

+       "width": 148

+     }

+   ],

+   "properties": [],

+   "tags": [

+     "sysmon_fsystems_shown"

+   ]

+ } 

\ No newline at end of file

@@ -0,0 +1,15 @@ 

+ {

+   "properties": [],

+   "tags": [

+     "sysmon_fsystems_shown"

+   ],

+   "area": [

+     {

+       "xpos": 1,

+       "ypos": 136,

+       "width": 148,

+       "height": 53,

+       "type": "match"

+     }

+   ]

+ } 

\ No newline at end of file

empty or binary file added
@@ -0,0 +1,15 @@ 

+ {

+   "area": [

+     {

+       "xpos": 9,

+       "ypos": 398,

+       "width": 138,

+       "height": 21,

+       "type": "match"

+     }

+   ],

+   "properties": [],

+   "tags": [

+     "sysmon_help_monitoring"

+   ]

+ } 

\ No newline at end of file

empty or binary file added
@@ -0,0 +1,15 @@ 

+ {

+   "area": [

+     {

+       "xpos": 131,

+       "ypos": 265,

+       "width": 111,

+       "height": 19,

+       "type": "match"

+     }

+   ],

+   "properties": [],

+   "tags": [

+     "sysmon_help_processor"

+   ]

+ } 

\ No newline at end of file

empty or binary file added
@@ -0,0 +1,15 @@ 

+ {

+   "area": [

+     {

+       "xpos": 15,

+       "ypos": 114,

+       "width": 306,

+       "height": 25,

+       "type": "match"

+     }

+   ],

+   "properties": [],

+   "tags": [

+     "sysmon_help_shown"

+   ]

+ } 

\ No newline at end of file

empty or binary file added
@@ -0,0 +1,15 @@ 

+ {

+   "area": [

+     {

+       "xpos": 503,

+       "ypos": 171,

+       "width": 79,

+       "height": 21,

+       "type": "match"

+     }

+   ],

+   "properties": [],

+   "tags": [

+     "sysmon_help_swap"

+   ]

+ } 

\ No newline at end of file

empty or binary file added
@@ -0,0 +1,15 @@ 

+ {

+   "area": [

+     {

+       "xpos": 149,

+       "ypos": 127,

+       "width": 88,

+       "height": 38,

+       "type": "match"

+     }

+   ],

+   "properties": [],

+   "tags": [

+     "sysmon_help_swap_shown"

+   ]

+ } 

\ No newline at end of file

empty or binary file added
@@ -0,0 +1,15 @@ 

+ {

+   "area": [

+     {

+       "xpos": 515,

+       "ypos": 365,

+       "width": 152,

+       "height": 24,

+       "type": "match"

+     }

+   ],

+   "properties": [],

+   "tags": [

+     "sysmon_help_use_maps"

+   ]

+ } 

\ No newline at end of file

empty or binary file added
@@ -0,0 +1,15 @@ 

+ {

+   "properties": [],

+   "tags": [

+     "sysmon_menu_about"

+   ],

+   "area": [

+     {

+       "xpos": 833,

+       "ypos": 369,

+       "width": 150,

+       "height": 20,

+       "type": "match"

+     }

+   ]

+ } 

\ No newline at end of file

empty or binary file added
@@ -0,0 +1,15 @@ 

+ {

+   "area": [

+     {

+       "xpos": 830,

+       "ypos": 311,

+       "width": 47,

+       "height": 30,

+       "type": "match"

+     }

+   ],

+   "properties": [],

+   "tags": [

+     "sysmon_menu_help"

+   ]

+ } 

\ No newline at end of file

empty or binary file added
@@ -0,0 +1,15 @@ 

+ {

+   "area": [

+     {

+       "xpos": 830,

+       "ypos": 289,

+       "width": 89,

+       "height": 24,

+       "type": "match"

+     }

+   ],

+   "properties": [],

+   "tags": [

+     "sysmon_menu_preferences"

+   ]

+ } 

\ No newline at end of file

empty or binary file added
@@ -0,0 +1,15 @@ 

+ {

+   "properties": [],

+   "tags": [

+     "sysmon_menu_shortcuts"

+   ],

+   "area": [

+     {

+       "xpos": 835,

+       "ypos": 341,

+       "width": 132,

+       "height": 23,

+       "type": "match"

+     }

+   ]

+ } 

\ No newline at end of file

empty or binary file added
@@ -0,0 +1,29 @@ 

+ {

+   "area": [

+     {

+       "xpos": 462,

+       "ypos": 55,

+       "width": 97,

+       "height": 23,

+       "type": "match"

+     },

+     {

+       "xpos": 603,

+       "ypos": 52,

+       "width": 51,

+       "height": 25,

+       "type": "match"

+     },

+     {

+       "xpos": 317,

+       "ypos": 51,

+       "width": 94,

+       "height": 28,

+       "type": "match"

+     }

+   ],

+   "properties": [],

+   "tags": [

+     "sysmon_preferences_shown"

+   ]

+ } 

\ No newline at end of file

empty or binary file added
@@ -0,0 +1,22 @@ 

+ {

+   "properties": [],

+   "tags": [

+     "sysmon_processes_shown"

+   ],

+   "area": [

+     {

+       "xpos": 315,

+       "ypos": 42,

+       "width": 100,

+       "height": 26,

+       "type": "match"

+     },

+     {

+       "xpos": 6,

+       "ypos": 80,

+       "width": 100,

+       "height": 23,

+       "type": "match"

+     }

+   ]

+ } 

\ No newline at end of file

empty or binary file added
@@ -0,0 +1,22 @@ 

+ {

+   "properties": [],

+   "tags": [

+     "sysmon_resources_shown"

+   ],

+   "area": [

+     {

+       "xpos": 64,

+       "ypos": 264,

+       "width": 41,

+       "height": 22,

+       "type": "match"

+     },

+     {

+       "xpos": 97,

+       "ypos": 472,

+       "width": 63,

+       "height": 21,

+       "type": "match"

+     }

+   ]

+ } 

\ No newline at end of file

empty or binary file added
@@ -0,0 +1,15 @@ 

+ {

+   "properties": [],

+   "tags": [

+     "sysmon_shortcuts_shown"

+   ],

+   "area": [

+     {

+       "xpos": 476,

+       "ypos": 166,

+       "width": 73,

+       "height": 23,

+       "type": "match"

+     }

+   ]

+ } 

\ No newline at end of file

empty or binary file added
@@ -0,0 +1,15 @@ 

+ {

+   "area": [

+     {

+       "type": "match",

+       "height": 20,

+       "ypos": 160,

+       "xpos": 165,

+       "width": 113

+     }

+   ],

+   "properties": [],

+   "tags": [

+     "systemmonitor_runs"

+   ]

+ } 

\ No newline at end of file

empty or binary file added
file modified
+16
@@ -1172,6 +1172,22 @@ 

                  "START_AFTER_TEST": "%DEPLOY_UPLOAD_TEST%"

              }

          },

+         "sysmon": {

+             "profiles": {

+                 "fedora-Silverblue-dvd_ostree-iso-ppc64le-*-ppc64le": 50,

+                 "fedora-Silverblue-dvd_ostree-iso-x86_64-*-64bit": 50,

+                 "fedora-Workstation-live-iso-ppc64le-*-ppc64le": 20,

+                 "fedora-Workstation-live-iso-x86_64-*-64bit": 20,

+                 "fedora-Workstation-upgrade-aarch64-*-aarch64": 40,

+                 "fedora-Workstation-raw_xz-raw.xz-aarch64-*-aarch64": 22

+             },

+             "settings": {

+                 "BOOTFROM": "c",

+                 "HDD_1": "disk_%FLAVOR%_%MACHINE%.qcow2",

+                 "POSTINSTALL_PATH": "tests/applications/sysmon",

+                 "START_AFTER_TEST": "%DEPLOY_UPLOAD_TEST%"

+             }

+         },

          "weather": {

              "profiles": {

                  "fedora-Silverblue-dvd_ostree-iso-ppc64le-*-ppc64le": 50,

@@ -0,0 +1,28 @@ 

+ use base "installedtest";

+ use strict;

+ use testapi;

+ use utils;

+ 

+ # This script opens the System Monitor application and saves the milestone

+ # to make it ready for further testing.

+ 

+ sub run {

+     my $self = shift;

+ 

+     # Start the Application

+     menu_launch_type("system monitor");

+     assert_screen("systemmonitor_runs");

+ 

+     # Make it fill the entire window.

+     send_key("super-up");

+     wait_still_screen(2);

+ }

+ 

+ sub test_flags {

+     # If this test fails, there is no need to continue.

+     return {fatal => 1, milestone => 1};

+ }

+ 

+ 1;

+ 

+ # vim: set sw=4 et:

@@ -0,0 +1,24 @@ 

+ use base "installedtest";

+ use strict;

+ use testapi;

+ use utils;

+ 

+ sub run {

+ 

+     # Open the Menu and click on the About entry.

+     assert_and_click("gnome_burger_menu");

+     assert_and_click("sysmon_menu_about");

+ 

+     # Check that About dialogue has started.

+     assert_screen("sysmon_about_shown");

+     # Click on the Credits button

+     assert_and_click("gnome_button_credits");

+     # Check that Credits are shown

+     assert_screen("sysmon_credits_shown");

+ }

+ 

+ sub test_flags {

+     return {always_rollback => 1};

+ }

+ 

+ 1;

@@ -0,0 +1,27 @@ 

+ use base "installedtest";

+ use strict;

+ use testapi;

+ use utils;

+ 

+ sub run {

+ 

+     # Open the Menu and click on Help entry.

+     assert_and_click("gnome_burger_menu");

+     assert_and_click("sysmon_menu_help");

+ 

+     # Check that Shortcuts dialogue is shown.

+     assert_screen("sysmon_help_shown");

+ 

+     assert_and_click("sysmon_help_processor");

+     assert_and_click("sysmon_help_monitoring");

+     assert_and_click("sysmon_help_use_maps");

+     assert_and_click("sysmon_help_swap");

+     assert_screen("sysmon_help_swap_shown");

+ }

+ 

+ sub test_flags {

+     return {always_rollback => 1};

+ }

+ 

+ 1;

+ 

@@ -0,0 +1,30 @@ 

+ use base "installedtest";

+ use strict;

+ use testapi;

+ use utils;

+ 

+ # This script tests that users can switch between the three main regimes.

+ 

+ sub run {

+     # wait for the restore to settle down

+     wait_still_screen 3;

+     # Press Alt-3 to see the file systems

+     send_key("alt-3");

+     assert_screen("sysmon_fsystems_shown");

+ 

+     # Press Alt-1 to see the processes

+     send_key("alt-1");

+     assert_screen("sysmon_processes_shown");

+ 

+     # Press Alt-2 to see the resources

+     send_key("alt-2");

+     assert_screen("sysmon_resources_shown");

+ }

+ 

+ sub test_flags {

+     return {always_rollback => 1};

+ }

+ 

+ 1;

+ 

+ 

@@ -0,0 +1,21 @@ 

+ use base "installedtest";

+ use strict;

+ use testapi;

+ use utils;

+ 

+ sub run {

+ 

+     # Open the Menu and click on Preferences entry.

+     assert_and_click("gnome_burger_menu");

+     assert_and_click("sysmon_menu_preferences");

+ 

+     # Check that Preferences dialogue is shown.

+     assert_screen("sysmon_preferences_shown");

+ }

+ 

+ sub test_flags {

+     return {always_rollback => 1};

+ }

+ 

+ 1;

+ 

@@ -0,0 +1,21 @@ 

+ use base "installedtest";

+ use strict;

+ use testapi;

+ use utils;

+ 

+ sub run {

+ 

+     # Open the Menu and click on Shortcuts entry.

+     assert_and_click("gnome_burger_menu");

+     assert_and_click("sysmon_menu_shortcuts");

+ 

+     # Check that Shortcuts dialogue is shown.

+     assert_screen("sysmon_shortcuts_shown");

+ }

+ 

+ sub test_flags {

+     return {always_rollback => 1};

+ }

+ 

+ 1;

+ 

This small test suite adds a bunch of tests for System Monitor.

Build succeeded.

rebased onto 093b06942854046af475a33dc6e9abd35081e8a5

2 years ago

I've loaded this PR onto stg/lab for testing now.

Build failed. More information on how to proceed and troubleshoot errors available at https://fedoraproject.org/wiki/Zuul-based-ci

rebased onto 666aea91d97bc8371ade77e3c8c26dc36312fc35

2 years ago

Build failed. More information on how to proceed and troubleshoot errors available at https://fedoraproject.org/wiki/Zuul-based-ci

rebased onto 607d26d8b868d759c6811ae6b0affe9b73ce7524

2 years ago

Build failed. More information on how to proceed and troubleshoot errors available at https://fedoraproject.org/wiki/Zuul-based-ci

rebased onto 18dc46167d7761bfabf95d8d5a47befde4a13e6e

2 years ago

Build failed. More information on how to proceed and troubleshoot errors available at https://fedoraproject.org/wiki/Zuul-based-ci

rebased onto 28def4918a006e81669f7201d8ef380a6f57cc01

2 years ago

Build failed. More information on how to proceed and troubleshoot errors available at https://fedoraproject.org/wiki/Zuul-based-ci

rebased onto 60d4bdfeb925ed9290d58469b3825461d16a962a

2 years ago

Build failed. More information on how to proceed and troubleshoot errors available at https://fedoraproject.org/wiki/Zuul-based-ci

rebased onto 870c30dc4f09388b45df732e2d02d9dbbe37f6ae

2 years ago

Build succeeded.

rebased onto 5d3fc24

2 years ago

Build succeeded.

OK, with a few tweaks this is working and I don't want to hold it up so I'll merge it, but note https://pagure.io/fedora-qa/os-autoinst-distri-fedora/issue/277 . Another thing is the set of flavors this runs on is kinda haphazard - why on upgrades for aarch64 but not x86_64? we should probably go through all the app tests and come up with a consistent approach here. Is it really worth the resources to run all these tests on live and also on upgrade?

Pull-Request has been merged by adamwill

2 years ago
Metadata
Changes Summary 45
+15
file added
needles/gnome/apps/sysmon/sysmon_about_shown.json
+0
file added
needles/gnome/apps/sysmon/sysmon_about_shown.png
+15
file added
needles/gnome/apps/sysmon/sysmon_credits_shown.json
+0
file added
needles/gnome/apps/sysmon/sysmon_credits_shown.png
+15
file added
needles/gnome/apps/sysmon/sysmon_fsystems_shown-silverblue-20221010.json
+0
file added
needles/gnome/apps/sysmon/sysmon_fsystems_shown-silverblue-20221010.png
+15
file added
needles/gnome/apps/sysmon/sysmon_fsystems_shown.json
+0
file added
needles/gnome/apps/sysmon/sysmon_fsystems_shown.png
+15
file added
needles/gnome/apps/sysmon/sysmon_help_monitoring.json
+0
file added
needles/gnome/apps/sysmon/sysmon_help_monitoring.png
+15
file added
needles/gnome/apps/sysmon/sysmon_help_processor.json
+0
file added
needles/gnome/apps/sysmon/sysmon_help_processor.png
+15
file added
needles/gnome/apps/sysmon/sysmon_help_shown.json
+0
file added
needles/gnome/apps/sysmon/sysmon_help_shown.png
+15
file added
needles/gnome/apps/sysmon/sysmon_help_swap.json
+0
file added
needles/gnome/apps/sysmon/sysmon_help_swap.png
+15
file added
needles/gnome/apps/sysmon/sysmon_help_swap_shown.json
+0
file added
needles/gnome/apps/sysmon/sysmon_help_swap_shown.png
+15
file added
needles/gnome/apps/sysmon/sysmon_help_use_maps.json
+0
file added
needles/gnome/apps/sysmon/sysmon_help_use_maps.png
+15
file added
needles/gnome/apps/sysmon/sysmon_menu_about.json
+0
file added
needles/gnome/apps/sysmon/sysmon_menu_about.png
+15
file added
needles/gnome/apps/sysmon/sysmon_menu_help.json
+0
file added
needles/gnome/apps/sysmon/sysmon_menu_help.png
+15
file added
needles/gnome/apps/sysmon/sysmon_menu_preferences.json
+0
file added
needles/gnome/apps/sysmon/sysmon_menu_preferences.png
+15
file added
needles/gnome/apps/sysmon/sysmon_menu_shortcuts.json
+0
file added
needles/gnome/apps/sysmon/sysmon_menu_shortcuts.png
+29
file added
needles/gnome/apps/sysmon/sysmon_preferences_shown.json
+0
file added
needles/gnome/apps/sysmon/sysmon_preferences_shown.png
+22
file added
needles/gnome/apps/sysmon/sysmon_processes_shown.json
+0
file added
needles/gnome/apps/sysmon/sysmon_processes_shown.png
+22
file added
needles/gnome/apps/sysmon/sysmon_resources_shown.json
+0
file added
needles/gnome/apps/sysmon/sysmon_resources_shown.png
+15
file added
needles/gnome/apps/sysmon/sysmon_shortcuts_shown.json
+0
file added
needles/gnome/apps/sysmon/sysmon_shortcuts_shown.png
+15
file added
needles/gnome/apps/systemmonitor_runs-20220921.json
+0
file added
needles/gnome/apps/systemmonitor_runs-20220921.png
+16 -0
file changed
templates.fif.json
+28
file added
tests/applications/sysmon/aaa_setup.pm
+24
file added
tests/applications/sysmon/about.pm
+27
file added
tests/applications/sysmon/help.pm
+30
file added
tests/applications/sysmon/main_view.pm
+21
file added
tests/applications/sysmon/preferences.pm
+21
file added
tests/applications/sysmon/shortcuts.pm