def _update_environment_for_testcase(testcase, build_directory): """Update environment variables that depend on the test case.""" commands.update_environment_for_job(testcase.job_definition) environment.set_value('JOB_NAME', testcase.job_type) fuzzer_directory = setup.get_fuzzer_directory(testcase.fuzzer_name) environment.set_value('FUZZER_DIR', fuzzer_directory) setup.prepare_environment_for_testcase(testcase) build_manager.set_environment_vars( [environment.get_value('FUZZER_DIR'), build_directory]) _verify_target_exists(build_directory)
def _update_environment_for_testcase(testcase, build_directory): """Update environment variables that depend on the test case.""" commands.update_environment_for_job(testcase.job_definition) environment.set_value('JOB_NAME', testcase.job_type) # Update APP_PATH now that we know the application name. app_path = os.path.join(build_directory, environment.get_value('APP_NAME')) environment.set_value('APP_PATH', app_path) fuzzer_directory = setup.get_fuzzer_directory(testcase.fuzzer_name) environment.set_value('FUZZER_DIR', fuzzer_directory) setup.prepare_environment_for_testcase(testcase) build_manager.set_environment_vars( [environment.get_value('FUZZER_DIR'), build_directory])
def _update_environment_for_testcase(testcase, build_directory, application_override): """Update environment variables that depend on the test case.""" commands.update_environment_for_job(testcase.job_definition) environment.set_value('JOB_NAME', testcase.job_type) # Override app name if explicitly specified. if application_override: environment.set_value('APP_NAME', application_override) fuzzer_directory = setup.get_fuzzer_directory(testcase.fuzzer_name) environment.set_value('FUZZER_DIR', fuzzer_directory) task_name = environment.get_value('TASK_NAME') setup.prepare_environment_for_testcase(testcase, testcase.job_type, task_name) build_manager.set_environment_vars( [environment.get_value('FUZZER_DIR'), build_directory]) _verify_target_exists(build_directory)