예제 #1
0
 def test_run(self):
     '''
     Test for Run nagios plugin and return all
      the data execution with cmd.run
     '''
     with patch.object(nagios, '_execute_cmd', return_value='A'):
         self.assertEqual(nagios.run('plugin'), 'A')
예제 #2
0
 def test_run(self):
     """
     Test for Run nagios plugin and return all
      the data execution with cmd.run
     """
     with patch.object(nagios, "_execute_cmd", return_value="A"):
         self.assertEqual(nagios.run("plugin"), "A")
예제 #3
0
파일: nagios_test.py 프로젝트: DaveQB/salt
 def test_run(self):
     '''
     Test for Run nagios plugin and return all
      the data execution with cmd.run
     '''
     with patch.object(nagios, '_execute_cmd', return_value='A'):
         self.assertEqual(nagios.run('plugin'), 'A')