-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Simplify mod::php unit tests #2482
base: main
Are you sure you want to change the base?
Conversation
spec/classes/mod/php_spec.rb
Outdated
facts[:os]['name'] == 'Rocky' || facts[:os]['name'] == 'AlmaLinux')) | ||
|
||
describe 'OS independent tests' do | ||
describe 'OS independent tests', unless: ['Debian', 'RedHat'].include?(facts[:os]['family']) || (facts[:os]['release']['major'].to_i >= 15 && facts[:os]['name'] == 'SLES') do |
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.
This makes changes. Previously it ran on EL7 but now that's skipped altogether.
describe 'OS independent tests' do | ||
skip_os = ['Debian', 'RedHat'] | ||
describe 'OS independent tests', | ||
unless: skip_os.include?(facts[:os]['family'] && facts[:os]['release']['major'].to_i > 7) || (facts[:os]['release']['major'].to_i >= 15 && facts[:os]['name'] == 'SLES') do |
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.
That's an interesting hack. Technically you're right that Debian > 7 should be skipped. Though I always find >= 8
easier to read than > 7
. Is that just me?
Summary
Provide a detailed description of all the changes present in this pull request.
Additional Context
Add any additional context about the problem here.
Related Issues (if any)
Mention any related issues or pull requests.
Checklist
puppet apply
)