Révision cf38fe4a
create tests for presence of the "global" chain
spec/classes/inet_filter_spec.rb | ||
---|---|---|
414 | 414 |
} |
415 | 415 |
end |
416 | 416 |
|
417 |
context 'chain global' do |
|
418 |
it { |
|
419 |
is_expected.to contain_concat('nftables-inet-filter-chain-global').with( |
|
420 |
path: '/etc/nftables/puppet-preflight/inet-filter-chain-global.nft', |
|
421 |
owner: 'root', |
|
422 |
group: 'root', |
|
423 |
mode: '0640', |
|
424 |
ensure_newline: true, |
|
425 |
) |
|
426 |
} |
|
427 |
it { |
|
428 |
is_expected.to contain_concat__fragment('nftables-inet-filter-chain-global-header').with( |
|
429 |
target: 'nftables-inet-filter-chain-global', |
|
430 |
content: %r{^chain global \{$}, |
|
431 |
order: '00', |
|
432 |
) |
|
433 |
} |
|
434 |
end |
|
435 |
|
|
417 | 436 |
context 'custom log prefix without variable substitution' do |
418 | 437 |
let(:pre_condition) { 'class{\'nftables\': log_prefix => "test "}' } |
419 | 438 |
|
Formats disponibles : Unified diff