示例#1
0
 def test_status(self):
     '''
     Test if it return the status for a service via s6,
     return pid if running.
     '''
     mock_run = MagicMock(return_value='salt')
     with patch.dict(s6.__salt__, {'cmd.run_stdout': mock_run}):
         self.assertEqual(s6.status('ssh'), '')
示例#2
0
 def test_status(self):
     """
     Test if it return the status for a service via s6,
     return pid if running.
     """
     mock_run = MagicMock(return_value="salt")
     with patch.dict(s6.__salt__, {"cmd.run_stdout": mock_run}):
         self.assertEqual(s6.status("ssh"), "")
示例#3
0
 def test_status(self):
     '''
     Test if it return the status for a service via s6,
     return pid if running.
     '''
     mock_run = MagicMock(return_value='salt')
     with patch.dict(s6.__salt__, {'cmd.run_stdout': mock_run}):
         self.assertEqual(s6.status('ssh'), '')