Skip to content

Commit

Permalink
test_locking: Tolerate CentOS Stream's versioning
Browse files Browse the repository at this point in the history
It's not a problem functionally, so explicitly allow it in the unit
test.

Signed-off-by: Zack Cerza <[email protected]>
  • Loading branch information
zmc committed Sep 6, 2023
1 parent eff288c commit 78ddaa6
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion teuthology/task/tests/test_locking.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@


class TestLocking(object):

def test_correct_os_type(self, ctx, config):
os_type = ctx.config.get("os_type")
if os_type is None:
Expand All @@ -17,6 +16,9 @@ def test_correct_os_version(self, ctx, config):
if ctx.config.get("os_type") == "debian":
pytest.skip('known issue with debian versions; see: issue #10878')
for remote in ctx.cluster.remotes.keys():
if ctx.config.get("os_type").lower() == "centos":
# CentOS Stream omits ".stream" in /etc/os-release
os_version = os_version.lower().replace(".stream", "", 1)
assert remote.inventory_info['os_version'] == os_version

def test_correct_machine_type(self, ctx, config):
Expand Down

0 comments on commit 78ddaa6

Please sign in to comment.