Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update for RHEL 10.0 version check. #440

Merged
merged 2 commits into from
Sep 23, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 7 additions & 2 deletions os_tests/tests/test_rhel_guest_image.py
Original file line number Diff line number Diff line change
Expand Up @@ -663,7 +663,12 @@ def test_check_boot_cmdline_parameters(self):
expect_ret=0,
msg="cat /proc/cmdline")
for line in lines:
if line == "net.ifnames=0" and float(product_id) >= 10.0:
# Skip the check for net.ifnames=0 if the product is RHEL 10 or higher
self.log.info("Skipping check for net.ifnames=0 as it is removed in RHEL 10 and later")
continue
self.assertIn(line, output, "%s is not in boot parameters" % line)

# crashkernel
product_id = utils_lib.get_product_id(self)
if float(product_id) >= 9.0:
Expand Down Expand Up @@ -880,7 +885,7 @@ def test_check_redhat_release(self):
msg="cat /etc/redhat-release")
match = re.search(r"\d+\.?\d+", output).group(0)
self.assertEqual(
self.vm.rhel_ver, match,
float(self.vm.rhel_ver), float(match),
"Release version mismatch in /etc/redhat-release -> %s" % output)
if float(self.vm.rhel_ver) >= 8.0:
cmd = "rpm -q redhat-release"
Expand Down Expand Up @@ -908,7 +913,7 @@ def test_check_redhat_release(self):
output).group(1)

self.assertEqual(
self.vm.rhel_ver, match,
float(self.vm.rhel_ver), float(match),
"Release version mismatch on redhat-release-server -> %s" % output)

def tearDown(self):
Expand Down
Loading