Beispiel #1
0
 def test_active_tcp(self):
     '''
     Test for return a dict containing information on all
      of the running TCP connections
     '''
     with patch.object(salt.utils.network, 'active_tcp', return_value='A'):
         self.assertEqual(network.active_tcp(), 'A')
Beispiel #2
0
 def test_active_tcp(self):
     '''
     Test for return a dict containing information on all
      of the running TCP connections
     '''
     with patch.object(salt.utils.network, 'active_tcp', return_value='A'):
         self.assertEqual(network.active_tcp(), 'A')
Beispiel #3
0
 def test_active_tcp(self):
     """
     Test for return a dict containing information on all
      of the running TCP connections
     """
     with patch.object(salt.utils.network, "active_tcp", return_value="A"):
         with patch.dict(network.__grains__, {"kernel": "Linux"}):
             self.assertEqual(network.active_tcp(), "A")