From 221c45769e56ffda0ac82bd035e0ef5f37706836 Mon Sep 17 00:00:00 2001 From: Tim Meusel Date: Thu, 12 Sep 2019 15:01:58 +0200 Subject: readd Debian 9/10 support --- spec/defines/chain_spec.rb | 2 +- spec/defines/rule_spec.rb | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'spec/defines') diff --git a/spec/defines/chain_spec.rb b/spec/defines/chain_spec.rb index 4a598b3..1a6bb44 100644 --- a/spec/defines/chain_spec.rb +++ b/spec/defines/chain_spec.rb @@ -30,7 +30,7 @@ describe 'ferm::chain', type: :define do is_expected.to contain_concat__fragment('filter-INPUT2-footer'). \ with_content(%r{LOG log-prefix 'INPUT2: ';}) end - if facts[:os]['release']['major'].to_i == 10 + if facts[:os]['name'] == 'Debian' it { is_expected.to contain_concat('/etc/ferm/ferm.d/chains/filter-INPUT2.conf') } else it { is_expected.to contain_concat('/etc/ferm.d/chains/filter-INPUT2.conf') } diff --git a/spec/defines/rule_spec.rb b/spec/defines/rule_spec.rb index 33ce169..5e4ad69 100644 --- a/spec/defines/rule_spec.rb +++ b/spec/defines/rule_spec.rb @@ -161,7 +161,7 @@ describe 'ferm::rule', type: :define do that_requires('Ferm::Chain[check-ssh]') end it { is_expected.to contain_concat__fragment('filter-INPUT-config-include') } - if facts[:os]['release']['major'].to_i == 10 + if facts[:os]['name'] == 'Debian' it { is_expected.to contain_concat('/etc/ferm/ferm.d/chains/filter-SSH.conf') } else it { is_expected.to contain_concat('/etc/ferm.d/chains/filter-SSH.conf') } -- cgit v1.2.3