From: Jan Vansteenkiste Date: Wed, 22 Aug 2012 16:00:37 +0000 (+0200) Subject: Added fixtures to test parsing negated addresses X-Git-Tag: 0.5.0~18^2~8 X-Git-Url: https://review.fuel-infra.org/gitweb?a=commitdiff_plain;h=5e5e5c50cdcafb7df27cfe17a8bfe7e5da42b77e;p=puppet-modules%2Fpuppetlabs-firewall.git Added fixtures to test parsing negated addresses --- diff --git a/spec/fixtures/iptables/conversion_hash.rb b/spec/fixtures/iptables/conversion_hash.rb index 580dc48..8fb77b0 100644 --- a/spec/fixtures/iptables/conversion_hash.rb +++ b/spec/fixtures/iptables/conversion_hash.rb @@ -89,6 +89,22 @@ ARGS_TO_HASH = { :destination => '2001:db8:4321::/48', }, }, + 'source_destination_negate_source' => { + :line => '-A INPUT -s ! 1.1.1.1 -d 2.2.2.2 -m comment --comment "000 negated source address"', + :table => 'filter', + :params => { + :source => '! 1.1.1.1/32', + :destination => '2.2.2.2/32', + }, + }, + 'source_destination_negate_destination' => { + :line => '-A INPUT -s 1.1.1.1 -d ! 2.2.2.2 -m comment --comment "000 negated destination address"', + :table => 'filter', + :params => { + :source => '1.1.1.1/32', + :destination => '! 2.2.2.2/32', + }, + }, 'dport_range_1' => { :line => '-A INPUT -m multiport --dports 1:1024 -m comment --comment "000 allow foo"', :table => 'filter',