From 603ee871c13fe0ed9776e91ee0d36c3caf2837f7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Luk=C3=A1=C5=A1=20R=C5=AF=C5=BEi=C4=8Dka?= Date: Tue, 31 Mar 2020 09:37:11 +0200 Subject: [PATCH] Prevent the Konqueror test from running on F32 and later. Rework changes after the review. --- main.pm | 16 +++++++++++++++- tests/apps_startstop/kde/konqueror.pm | 1 - 2 files changed, 15 insertions(+), 2 deletions(-) diff --git a/main.pm b/main.pm index 9ee452d8..fac80ce8 100644 --- a/main.pm +++ b/main.pm @@ -21,6 +21,7 @@ use testapi; use autotest; use needle; use File::Basename; +use utils; # distribution-specific implementations of expected methods my $distri = testapi::get_var("CASEDIR") . '/lib/fedoradistribution.pm'; @@ -393,10 +394,23 @@ if (get_var("STARTSTOP")) { # Find all tests from a directory defined by the DESKTOP variable my @apptests = glob "${casedir}/tests/apps_startstop/${desktop}/*.pm"; + # We need to know the release number in order to make a decision based + # on the version - see later. + my $release = utils::get_release_number(); # Now load them foreach my $filepath (@apptests) { my $file = basename($filepath); - autotest::loadtest "tests/apps_startstop/${desktop}/${file}"; + # Konqueror has been removed from default installed applications and + # its test was constantly failing. The following will only run the + # Konqueror tests when the version is less than 32. Other tests + # should stay unaffected by this change. + # FIXME: Revert this change when we are done testing older versions. + if (($file eq "konqueror.pm") and ($release >= 32)) { + print "\nSkipping the Konqueror test in this version.\n"; + } + else { + autotest::loadtest "tests/apps_startstop/${desktop}/${file}"; + } } if ($desktop eq 'gnome') { # Run this test to check if required application have registered. diff --git a/tests/apps_startstop/kde/konqueror.pm b/tests/apps_startstop/kde/konqueror.pm index 496c5736..9ad9e4c2 100644 --- a/tests/apps_startstop/kde/konqueror.pm +++ b/tests/apps_startstop/kde/konqueror.pm @@ -7,7 +7,6 @@ use utils; sub run { my $self = shift; - # Start the application menu_launch_type 'konqueror'; # Check that it is started