From ec84f927f2614fdd109e6313412e6579c54f00c1 Mon Sep 17 00:00:00 2001 From: Trevor Cooper Date: Sat, 30 Dec 2023 11:21:27 -0800 Subject: [PATCH] update package switched to acpica-tools --- lib/packagetest.pm | 20 ++++++++++---------- tests/base_update_cli.pm | 22 ++++++---------------- 2 files changed, 16 insertions(+), 26 deletions(-) diff --git a/lib/packagetest.pm b/lib/packagetest.pm index ad17bacc..df95d1fe 100644 --- a/lib/packagetest.pm +++ b/lib/packagetest.pm @@ -9,15 +9,15 @@ use testapi; our @EXPORT = qw/prepare_test_packages verify_installed_packages verify_updated_packages/; # enable the openqa test package repositories and install the main -# test packages, remove pandoc-common and install the fake one +# test packages, remove acpica-tools and install the fake one sub prepare_test_packages { - # remove pandoc-common if installed (we don't use assert + # remove acpica-tools if installed (we don't use assert # here in case it's not) - script_run 'dnf -y remove pandoc-common', 180; + script_run 'dnf -y remove acpica-tools', 180; # grab the test repo definitions assert_script_run 'curl -o /etc/yum.repos.d/openqa-testrepo-1.repo https://git.resf.org/testing/openqa-testrepos/raw/branch/main/openqa-testrepo-1.repo'; # install the test packages from repo1 - assert_script_run 'dnf -y --disablerepo=* --enablerepo=openqa-testrepo-1 install pandoc-common'; + assert_script_run 'dnf -y --disablerepo=* --enablerepo=openqa-testrepo-1 install acpica-tools'; if (get_var("DESKTOP") eq 'kde' && get_var("TEST") eq 'desktop_update_graphical') { # kick pkcon so our special update will definitely get installed assert_script_run 'pkcon refresh force'; @@ -27,15 +27,15 @@ sub prepare_test_packages { # check our test packages installed correctly (this is a test that dnf # actually does what it claims) sub verify_installed_packages { - validate_script_output 'rpm -q pandoc-common', sub { $_ =~ m/^pandoc-common-1.1.noarch$/ }; - assert_script_run 'rpm -V pandoc-common'; + validate_script_output 'rpm -q acpica-tools', sub { $_ =~ m/^acpica-tools-1-1.noarch$/ }; + assert_script_run 'rpm -V acpica-tools'; } -# check updating the test packages and the fake pandoc-common work +# check updating the test packages and the fake acpica-tools work # as expected sub verify_updated_packages { - # we don't know what version of pandoc-common we'll actually + # we don't know what version of acpica-tools we'll actually # get, so just check it's *not* the fake one - validate_script_output 'rpm -q pandoc-common', sub { $_ !~ m/^pandoc-common-1-1.noarch$/ }; - assert_script_run 'rpm -V pandoc-common'; + validate_script_output 'rpm -q acpica-tools', sub { $_ !~ m/^acpica-tools-1-1.noarch$/ }; + assert_script_run 'rpm -V acpica-tools'; } diff --git a/tests/base_update_cli.pm b/tests/base_update_cli.pm index b59416e1..f147a77b 100644 --- a/tests/base_update_cli.pm +++ b/tests/base_update_cli.pm @@ -15,29 +15,19 @@ sub run { # check rpm agrees they installed good verify_installed_packages; - if (get_var("DISTRI") eq "rocky") { - if (get_version_major() < 9) { - # pandoc-common is in PowerTools in Rocky Linux 8 - assert_script_run 'dnf config-manager --set-enabled powertools', 60; - } - else { - # pandoc-common is in CRB in Rocky Linux 8 - assert_script_run 'dnf config-manager --set-enabled crb', 60; - } - } - # update the fake pandoc-common (should come from the real repo) + # update the fake acpica-tools (should come from the real repo) # this can take a long time if we get unlucky with the metadata refresh - assert_script_run 'dnf -y --disablerepo=openqa-testrepo* --disablerepo=updates-testing update pandoc-common', 600; + assert_script_run 'dnf -y --disablerepo=openqa-testrepo* update acpica-tools', 600; # check we got the updated version verify_updated_packages; - # now remove pandoc-common, and see if we can do a straight + # now remove acpica-tools, and see if we can do a straight # install from the default repos - assert_script_run 'dnf -y remove pandoc-common'; - assert_script_run 'dnf -y --disablerepo=openqa-testrepo* --disablerepo=updates-testing install pandoc-common', 120; - assert_script_run 'rpm -V pandoc-common'; + assert_script_run 'dnf -y remove acpica-tools'; + assert_script_run 'dnf -y --disablerepo=openqa-testrepo* install acpica-tools', 120; + assert_script_run 'rpm -V acpica-tools'; } sub test_flags {