Esempio n. 1
0
 def test_get_hostname(self):
     '''
     Test for Get hostname
     '''
     with patch.object(network.socket, 'gethostname', return_value='A'):
         self.assertEqual(network.get_hostname(), 'A')
Esempio n. 2
0
 def test_get_hostname(self):
     '''
     Test for Get hostname
     '''
     with patch.object(network.socket, 'gethostname', return_value='A'):
         self.assertEqual(network.get_hostname(), 'A')
Esempio n. 3
0
 def test_get_hostname(self):
     """
     Test for Get hostname
     """
     with patch.object(socket, "gethostname", return_value="A"):
         self.assertEqual(network.get_hostname(), "A")