def _call_find_tests(self, test_data, options=None):
     popen_mock = PopenMock(test_data)
     options = self._process_options(options or [])
     with guard_patch_module('subprocess.Popen', popen_mock):
         tasks = gtest_parallel.find_tests(test_data.keys(), [], options,
                                           TestTimesMock(self, test_data))
     return tasks, popen_mock
 def _call_find_tests(self, test_data, options=None):
   subprocess_mock = SubprocessMock(test_data)
   options = self._process_options(options or [])
   with guard_patch_module('subprocess.check_output', subprocess_mock):
     tasks = gtest_parallel.find_tests(
       test_data.keys(), [], options, TestTimesMock(self, test_data))
   # Clean transient tasks' log files created because
   # by default now output_dir is None.
   for task in tasks:
     if os.path.isfile(task.log_file):
       os.remove(task.log_file)
   return tasks, subprocess_mock
Example #3
0
 def _call_find_tests(self, test_data, options=None):
   subprocess_mock = SubprocessMock(test_data)
   options = self._process_options(options or [])
   with guard_patch_module('subprocess.check_output', subprocess_mock):
     tasks = gtest_parallel.find_tests(
       test_data.keys(), [], options, TestTimesMock(self, test_data))
   # Clean transient tasks' log files created because
   # by default now output_dir is None.
   for task in tasks:
     if os.path.isfile(task.log_file):
       os.remove(task.log_file)
   return tasks, subprocess_mock