def test_add_rich_rule(self): ''' Test adding a rich rule to a zone ''' with patch.object(firewalld, '__firewall_cmd', return_value='success'): self.assertEqual( firewalld.add_rich_rule( 'zone', 'rule family="ipv4" source address="1.2.3.4" accept'), 'success')
def test_add_rich_rule(self): """ Test adding a rich rule to a zone """ with patch.object(firewalld, "__firewall_cmd", return_value="success"): self.assertEqual( firewalld.add_rich_rule( "zone", 'rule family="ipv4" source address="1.2.3.4" accept'), "success", )
def test_add_rich_rule(self): ''' Test adding a rich rule to a zone ''' with patch.object(firewalld, '__firewall_cmd', return_value='success'): self.assertEqual(firewalld.add_rich_rule('zone', 'rule family="ipv4" source address="1.2.3.4" accept'), 'success')