MCPcopy Create free account
hub / github.com/boostorg/build / __init__

Method __init__

v2/test/TestCmd.py:215–248  ·  view source on GitHub ↗
(self, description=None, program=None, workdir=None,
        subdir=None, verbose=False, match=None, inpath=None)

Source from the content-addressed store, hash-verified

213
214class TestCmd:
215 def __init__(self, description=None, program=None, workdir=None,
216 subdir=None, verbose=False, match=None, inpath=None):
217
218 self._cwd = os.getcwd()
219 self.description_set(description)
220 self.program_set(program, inpath)
221 self.verbose_set(verbose)
222 if match is None:
223 self.match_func = match_re
224 else:
225 self.match_func = match
226 self._dirlist = []
227 self._preserve = {'pass_test': 0, 'fail_test': 0, 'no_result': 0}
228 env = os.environ.get('PRESERVE')
229 if env:
230 self._preserve['pass_test'] = env
231 self._preserve['fail_test'] = env
232 self._preserve['no_result'] = env
233 else:
234 env = os.environ.get('PRESERVE_PASS')
235 if env is not None:
236 self._preserve['pass_test'] = env
237 env = os.environ.get('PRESERVE_FAIL')
238 if env is not None:
239 self._preserve['fail_test'] = env
240 env = os.environ.get('PRESERVE_PASS')
241 if env is not None:
242 self._preserve['PRESERVE_NO_RESULT'] = env
243 self._stdout = []
244 self._stderr = []
245 self.status = None
246 self.condition = 'no_result'
247 self.workdir_set(workdir)
248 self.subdir(subdir)
249
250 def __del__(self):
251 self.cleanup()

Callers

nothing calls this directly

Calls 6

description_setMethod · 0.95
program_setMethod · 0.95
verbose_setMethod · 0.95
workdir_setMethod · 0.95
subdirMethod · 0.95
getMethod · 0.80

Tested by

no test coverage detected