Skip to content

Commit ed3e96b

Browse files
committed
Fix lint issues
1 parent 277d78f commit ed3e96b

File tree

2 files changed

+7
-4
lines changed

2 files changed

+7
-4
lines changed

manifests/repo.pp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,9 @@
6767

6868
case $facts['os']['family'] {
6969
'Debian': {
70-
unless $facts['os']['release']['major'] in ['9', '10', '11'] or $facts['os']['release']['major'] in ['16.04', '18.04', '20.04', '22.04'] {
70+
$supported_debian = $facts['os']['release']['major'] in ['9', '10', '11']
71+
$supported_ubuntu = $facts['os']['release']['major'] in ['16.04', '18.04', '20.04', '22.04']
72+
unless $supported_debian or $supported_ubuntu {
7173
fail($unsupported)
7274
}
7375

spec/classes/license_spec.rb

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,20 +9,21 @@
99
test_content = 'test-license-content'
1010
let(:facts) { os_facts }
1111

12-
1312
describe 'without params' do
14-
it { is_expected.to compile.and_raise_error(/.*/) }
13+
it { is_expected.to compile.and_raise_error(%r{/.*/}) }
1514
end
1615

1716
describe 'with Puppet URL for source' do
1817
let(:params) { { source: file_uri } }
18+
1919
it { is_expected.to compile }
2020
it { is_expected.to contain_class('zend_common::license').with_source(file_uri) }
2121
it { is_expected.to contain_file('/opt/zend/zendphp/etc/license').with_source(file_uri) }
2222
end
23-
23+
2424
describe 'with text for content' do
2525
let(:params) { { content: test_content } }
26+
2627
it { is_expected.to compile }
2728
it { is_expected.to contain_class('zend_common::license').with_content(test_content) }
2829
it { is_expected.to contain_file('/opt/zend/zendphp/etc/license').with_content(test_content) }

0 commit comments

Comments
 (0)