def generate_yaml(): return { 'tests': [ { 'name': 'json_run_localhost', 'shortname': 'json_run_localhost:%s' % scenario_json['name'], 'args': ['--scenarios_json', _scenario_json_string(scenario_json, False)], 'ci_platforms': ['linux'], 'platforms': ['linux'], 'flaky': False, 'language': 'c++', 'boringssl': True, 'defaults': 'boringssl', 'cpu_cost': guess_cpu(scenario_json, False), 'exclude_configs': ['tsan', 'asan'] + maybe_exclude_gcov(scenario_json), 'timeout_seconds': 2*60, 'excluded_poll_engines': scenario_json.get('EXCLUDED_POLL_ENGINES', []), 'auto_timeout_scaling': False } for scenario_json in scenario_config.CXXLanguage().scenarios() if 'scalable' in scenario_json.get('CATEGORIES', []) ] + [ { 'name': 'qps_json_driver', 'shortname': 'qps_json_driver:inproc_%s' % scenario_json['name'], 'args': ['--run_inproc', '--scenarios_json', _scenario_json_string(scenario_json, False)], 'ci_platforms': ['linux'], 'platforms': ['linux'], 'flaky': False, 'language': 'c++', 'boringssl': True, 'defaults': 'boringssl', 'cpu_cost': guess_cpu(scenario_json, False), 'exclude_configs': ['tsan', 'asan'], 'timeout_seconds': 6*60, 'excluded_poll_engines': scenario_json.get('EXCLUDED_POLL_ENGINES', []) } for scenario_json in scenario_config.CXXLanguage().scenarios() if 'inproc' in scenario_json.get('CATEGORIES', []) ] + [ { 'name': 'json_run_localhost', 'shortname': 'json_run_localhost:%s_low_thread_count' % scenario_json['name'], 'args': ['--scenarios_json', _scenario_json_string(scenario_json, True)], 'ci_platforms': ['linux'], 'platforms': ['linux'], 'flaky': False, 'language': 'c++', 'boringssl': True, 'defaults': 'boringssl', 'cpu_cost': guess_cpu(scenario_json, True), 'exclude_configs': sorted(c for c in configs_from_yaml if c not in ('tsan', 'asan')), 'timeout_seconds': 10*60, 'excluded_poll_engines': scenario_json.get('EXCLUDED_POLL_ENGINES', []), 'auto_timeout_scaling': False } for scenario_json in scenario_config.CXXLanguage().scenarios() if 'scalable' in scenario_json.get('CATEGORIES', []) ] }
'name': 'json_run_localhost', 'shortname': 'json_run_localhost:%s' % scenario_json['name'], 'args': ['--scenarios_json', _scenario_json_string(scenario_json, False)], 'ci_platforms': ['linux'], 'platforms': ['linux'], 'flaky': False, 'language': 'c++', 'boringssl': True, 'defaults': 'boringssl', 'cpu_cost': guess_cpu(scenario_json, False), 'exclude_configs': ['tsan', 'asan'], 'timeout_seconds': 6 * 60, 'excluded_poll_engines': scenario_json.get('EXCLUDED_POLL_ENGINES', []) } for scenario_json in scenario_config.CXXLanguage().scenarios() if 'scalable' in scenario_json.get('CATEGORIES', [])] + [{ 'name': 'json_run_localhost', 'shortname': 'json_run_localhost:%s_low_thread_count' % scenario_json['name'], 'args': ['--scenarios_json', _scenario_json_string(scenario_json, True)], 'ci_platforms': ['linux'], 'platforms': ['linux'], 'flaky': False, 'language': 'c++',
import json import pipes import shutil import sys import os import yaml run_tests_root = os.path.abspath( os.path.join(os.path.dirname(sys.argv[0]), '../../../tools/run_tests')) sys.path.append(run_tests_root) import performance.scenario_config as scenario_config print yaml.dump({ 'tests': [{ 'name': 'json_run_localhost', 'shortname': 'json_run_localhost:%s' % js['name'], 'args': ['--scenario_json', pipes.quote(json.dumps(js))], 'ci_platforms': ['linux', 'mac', 'posix', 'windows'], 'platforms': ['linux', 'mac', 'posix', 'windows'], 'flaky': False, 'language': 'c++', 'boringssl': True, 'defaults': 'boringssl', 'cpu_cost': 1000.0, 'exclude_configs': [] } for js in scenario_config.CXXLanguage().scenarios()] })
def generate_qps_json_driver_scenarios(): return [ _mutate_scenario(scenario_json) for scenario_json in scenario_config.CXXLanguage().scenarios() if 'inproc' in scenario_json.get('CATEGORIES', []) ]
def generate_json_run_localhost_scenarios(): return [ _mutate_scenario(scenario_json) for scenario_json in scenario_config.CXXLanguage().scenarios() if 'scalable' in scenario_json.get('CATEGORIES', []) ]