File tree 1 file changed +28
-0
lines changed
1 file changed +28
-0
lines changed Original file line number Diff line number Diff line change 367
367
it { is_expected . to contain_file ( '/etc/zabbix/zabbix_server.conf' ) . without_content %r{^StartODBCPollers=1} }
368
368
end
369
369
370
+ context 'with zabbix_server.conf and version 7.0' do
371
+ next if facts [ :os ] [ 'name' ] == 'Debian' && facts [ :os ] [ 'release' ] [ 'major' ] . to_i <= 12
372
+ next if facts [ :os ] [ 'name' ] == 'Ubuntu' && facts [ :os ] [ 'release' ] [ 'major' ] . to_i <= 20
373
+
374
+ let :params do
375
+ {
376
+ smsdevices : '/dev/ttyS0' ,
377
+ zabbix_version : '7.0'
378
+ }
379
+ end
380
+
381
+ it { is_expected . to contain_file ( '/etc/zabbix/zabbix_server.conf' ) . with_content %r{^SMSDevices=/dev/ttyS0} }
382
+ end
383
+
384
+ context 'with zabbix_server.conf and version 7.2' do
385
+ next if facts [ :os ] [ 'name' ] == 'Debian' && facts [ :os ] [ 'release' ] [ 'major' ] . to_i <= 12
386
+ next if facts [ :os ] [ 'name' ] == 'Ubuntu' && facts [ :os ] [ 'release' ] [ 'major' ] . to_i <= 20
387
+
388
+ let :params do
389
+ {
390
+ smsdevices : '/dev/ttyS0' ,
391
+ zabbix_version : '7.2'
392
+ }
393
+ end
394
+
395
+ it { is_expected . to contain_file ( '/etc/zabbix/zabbix_server.conf' ) . with_content %r{^SMSDevices=/dev/ttyS0} }
396
+ end
397
+
370
398
context 'with zabbix_server.conf and logtype declared' do
371
399
describe 'as system' do
372
400
let :params do
You can’t perform that action at this time.
0 commit comments