def t12():
pretty = '%s t12' % __file__
print(pretty)
w = Workspace(uid='vcsjob-execute-t12')
jobs = make_vcsjob_tree(w)
os.unsetenv('PATH')
exc = None
try:
vcsjob.execute_tags(jobs, None, ['PATH'])
except Exception, e:
exc = e
if not exc:
print(
'FAIL %s: vcsjob.fetch.run() with junk --env did not fail'
% pretty
)
return
# check the error message
if not str(exc).startswith('environment variable "PATH" is not set'):
print('FAIL %s: wrong error message: %s' % (pretty, str(exc)))
return
w.delete()
# check that correct value is returned by vcsjob.execute_single()
评论列表
文章目录