Esempio n. 1
0
 def test_list_zones(self):
     """
     Test for List everything added for or enabled in all zones
     """
     with patch.object(firewalld, "__firewall_cmd", return_value=[]):
         self.assertEqual(firewalld.default_zone(), [])
Esempio n. 2
0
 def test_default_zone(self):
     """
     Test for Print default zone for connections and interfaces
     """
     with patch.object(firewalld, "__firewall_cmd", return_value="A"):
         self.assertEqual(firewalld.default_zone(), "A")
Esempio n. 3
0
 def test_list_zones(self):
     '''
     Test for List everything added for or enabled in all zones
     '''
     with patch.object(firewalld, '__firewall_cmd', return_value=[]):
         self.assertEqual(firewalld.default_zone(), [])
Esempio n. 4
0
 def test_default_zone(self):
     '''
     Test for Print default zone for connections and interfaces
     '''
     with patch.object(firewalld, '__firewall_cmd', return_value='A'):
         self.assertEqual(firewalld.default_zone(), 'A')
Esempio n. 5
0
 def test_default_zone(self):
     '''
     Test for Print default zone for connections and interfaces
     '''
     with patch.object(firewalld, '__firewall_cmd', return_value='A'):
         self.assertEqual(firewalld.default_zone(), 'A')