-
Notifications
You must be signed in to change notification settings - Fork 125
Add RHEL 10 to OS path fixture #18808
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
base: master
Are you sure you want to change the base?
Conversation
trigger: test-robottelo |
PRT Result
|
pytest_fixtures/component/os.py
Outdated
elif default_os.major == "10": | ||
os_distr_url = settings.repos.rhel10_os.baseos |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd suggest to make this fixture future-proof with something like
elif default_os.major == "10": | |
os_distr_url = settings.repos.rhel10_os.baseos | |
if int(default_os.major) <= 7: | |
os_distr_url = getattr(settings.repos, f'rhel{default_os.major}_os') | |
elif int(default_os.major) > 7: | |
os_distro_url = getattr(settings.repos, f'rhel{default_os.major}_os').baseos | |
else: | |
pytest.fail('Proposed RHEL version is not supported') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why not. When doing these changes, I intend to keep them minimal but this little refactor should be ok.
@@ -47,6 +47,8 @@ def os_path(default_os): | |||
os_distr_url = settings.repos.rhel8_os.baseos | |||
elif default_os.major == "9": | |||
os_distr_url = settings.repos.rhel9_os.baseos | |||
elif default_os.major == "10": | |||
os_distr_url = settings.repos.rhel10_os.baseos | |||
else: | |||
pytest.fail('Proposed RHEL version is not supported') | |||
return os_distr_url |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
s/os_distr_url/os_distro_url
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No, it's really os_distr_url
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What does it mean?
trigger: test-robottelo |
PRT Result
|
trigger: test-robottelo |
PRT Result
|
No description provided.