Skip to content

Commit

Permalink
test: pcp: remove conditionals for python3-pcp
Browse files Browse the repository at this point in the history
All our rpm based images should have python3-pcp by now.
  • Loading branch information
jelly committed Oct 3, 2024
1 parent 7957a12 commit de91533
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 14 deletions.
7 changes: 1 addition & 6 deletions test/verify/check-client
Original file line number Diff line number Diff line change
Expand Up @@ -41,13 +41,8 @@ class TestClient(testlib.MachineCase):
elif self.m_target.image == 'arch':
self.m_target.execute("pacman -Rdd --noconfirm pcp")
else:
# TODO: remove conditional when all images have python3-pcp and a Python PCP bridge
self.m_target.execute("""
if rpm -q python3-pcp; then
rpm --erase --verbose pcp python3-pcp
else
rpm --erase --verbose pcp
fi
rpm --erase --verbose pcp python3-pcp
systemctl daemon-reload
""")

Expand Down
9 changes: 1 addition & 8 deletions test/verify/check-metrics
Original file line number Diff line number Diff line change
Expand Up @@ -1298,14 +1298,7 @@ class TestMetricsPackages(packagelib.PackageCase):
# HACK: pcp does not clean up correctly on Debian https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=986074
m.execute("rm -f /etc/systemd/system/pmlogger.service.requires/pmlogger_farm.service")
else:
# TODO: remove conditional when all images have python3-pcp and a Python PCP bridge
m.execute(f"""
if rpm -q python3-pcp; then
rpm --erase --verbose pcp python3-pcp {redis_package} {extra_packages}
else
rpm --erase --verbose pcp {redis_package} {extra_packages}
fi
""")
m.execute(f"rpm --erase --verbose pcp python3-pcp {redis_package} {extra_packages}")

dummy_service = "[Service]\nExecStart=/bin/sleep infinity\n[Install]\nWantedBy=multi-user.target\n"

Expand Down

0 comments on commit de91533

Please sign in to comment.