diff --git a/tests/foreman/api/test_capsulecontent.py b/tests/foreman/api/test_capsulecontent.py index 120b0c0354e..cdc388fd149 100644 --- a/tests/foreman/api/test_capsulecontent.py +++ b/tests/foreman/api/test_capsulecontent.py @@ -297,6 +297,7 @@ def test_positive_sync_updated_repo( cv = cv.read() assert len(cv.version) == 2 + cv.version.sort(key=lambda version: version.id) cvv = cv.version[-1].read() cvv.promote(data={'environment_ids': function_lce.id}) cvv = cvv.read()