Projet

Général

Profil

Révision cf38fe4a

IDcf38fe4aadbb25ae8aa00af643e5f1c09f53e749
Parent 1a4f336e
Enfant 942569ea

Ajouté par Gabriel Filion il y a plus de 4 ans

create tests for presence of the "global" chain

Voir les différences:

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