Skip to content

Commit

Permalink
converting mimimum version to semver object before comparison
Browse files Browse the repository at this point in the history
  • Loading branch information
umfranci committed Sep 19, 2024
1 parent a5ef096 commit ed6c126
Showing 1 changed file with 4 additions and 8 deletions.
12 changes: 4 additions & 8 deletions microsoft/testsuites/network/networksettings.py
Original file line number Diff line number Diff line change
Expand Up @@ -368,16 +368,12 @@ def verify_device_rss_hash_key_change(self, node: Node, log: Logger) -> None:
uname = node.tools[Uname]
linux_info = uname.get_linux_information()

min_supported_kernel = linux_info.kernel_version
if isinstance(node.os, Debian) or isinstance(node.os, Redhat):
min_supported_kernel = "5.0.0"
min_supported_kernel = parse_version("5.0.0")
elif isinstance(node.os, Suse):
min_supported_kernel = "4.12.14"
else:
# For other OS, it is not known which minimum kernel version
# supports RSS Hash key change. This can be found and later
# enhanced after running tests.
min_supported_kernel = str(linux_info.kernel_version)

min_supported_kernel = parse_version("4.12.14")

if linux_info.kernel_version < min_supported_kernel:
raise SkippedException(
f"The kernel version {linux_info.kernel_version} does not support"
Expand Down

0 comments on commit ed6c126

Please sign in to comment.