|
|
|
@ -149,6 +149,17 @@ class CLanguage(object): |
|
|
|
|
def test_specs(self): |
|
|
|
|
out = [] |
|
|
|
|
binaries = get_c_tests(self.args.travis, self.test_lang) |
|
|
|
|
POLLING_STRATEGIES = { |
|
|
|
|
'windows': ['all'], |
|
|
|
|
'mac': ['all'], |
|
|
|
|
'posix': ['all'], |
|
|
|
|
'linux': ['poll', 'legacy'] |
|
|
|
|
} |
|
|
|
|
for polling_strategy in POLLING_STRATEGIES[self.platform]: |
|
|
|
|
env={'GRPC_DEFAULT_SSL_ROOTS_FILE_PATH': |
|
|
|
|
_ROOT + '/src/core/tsi/test_creds/ca.pem', |
|
|
|
|
'GRPC_POLLING_STRATEGY': polling_strategy} |
|
|
|
|
shortname_ext = '' if polling_strategy=='all' else ' polling=%s' % polling_strategy |
|
|
|
|
for target in binaries: |
|
|
|
|
if self.config.build_config in target['exclude_configs']: |
|
|
|
|
continue |
|
|
|
@ -159,15 +170,6 @@ class CLanguage(object): |
|
|
|
|
target['name']) |
|
|
|
|
else: |
|
|
|
|
binary = 'bins/%s/%s' % (self.config.build_config, target['name']) |
|
|
|
|
env = {} |
|
|
|
|
shortname_ext = '' |
|
|
|
|
if 'env' in target: |
|
|
|
|
tenv = target['env'] |
|
|
|
|
env.update(tenv) |
|
|
|
|
shortname_ext += ' ' |
|
|
|
|
shortname_ext += ' '.join('%s=%s' % (key, tenv[key]) for key in sorted(tenv.keys())) |
|
|
|
|
env['GRPC_DEFAULT_SSL_ROOTS_FILE_PATH'] = ( |
|
|
|
|
_ROOT + '/src/core/tsi/test_creds/ca.pem') |
|
|
|
|
if os.path.isfile(binary): |
|
|
|
|
if 'gtest' in target and target['gtest']: |
|
|
|
|
# here we parse the output of --gtest_list_tests to build up a |
|
|
|
@ -190,7 +192,7 @@ class CLanguage(object): |
|
|
|
|
test = base + line.strip() |
|
|
|
|
cmdline = [binary] + ['--gtest_filter=%s' % test] |
|
|
|
|
out.append(self.config.job_spec(cmdline, [binary], |
|
|
|
|
shortname='%s:%s %s' % (binary, test, shortname_ext), |
|
|
|
|
shortname='%s:%s' % (binary, test, shortname_ext), |
|
|
|
|
cpu_cost=target['cpu_cost'], |
|
|
|
|
environ=env)) |
|
|
|
|
else: |
|
|
|
|