本文整理匯總了Python中TestRunner.inferClangCC方法的典型用法代碼示例。如果您正苦於以下問題:Python TestRunner.inferClangCC方法的具體用法?Python TestRunner.inferClangCC怎麽用?Python TestRunner.inferClangCC使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類TestRunner
的用法示例。
在下文中一共展示了TestRunner.inferClangCC方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Python代碼示例。
示例1: in
# 需要導入模塊: import TestRunner [as 別名]
# 或者: from TestRunner import inferClangCC [as 別名]
cfg = TestingConfig.frompath(opts.config)
# Update the configuration based on the command line arguments.
for name in ('PATH','SYSTEMROOT'):
if name in cfg.environment:
parser.error("'%s' should not be set in configuration!" % name)
cfg.root = opts.root
cfg.environment['PATH'] = os.pathsep.join(opts.path +
[os.environ.get('PATH','')])
cfg.environment['SYSTEMROOT'] = os.environ.get('SYSTEMROOT','')
if opts.clang is None:
opts.clang = TestRunner.inferClang(cfg)
if opts.clangcc is None:
opts.clangcc = TestRunner.inferClangCC(cfg, opts.clang)
cfg.clang = opts.clang
cfg.clangcc = opts.clangcc
cfg.useValgrind = opts.useValgrind
cfg.useExternalShell = opts.useExternalShell
# FIXME: It could be worth loading these in parallel with testing.
allTests = list(getTests(cfg, args))
allTests.sort()
tests = allTests
if opts.shuffle:
random.shuffle(tests)
if opts.maxTests is not None:
tests = tests[:opts.maxTests]