From bfc96872dde7b0074b576a2ce384c808588193c1 Mon Sep 17 00:00:00 2001 From: Yujun Zhang Date: Fri, 7 Oct 2016 16:33:44 +0800 Subject: Rename `suit` to `suite` We should use correct words for naming. Change-Id: Ia1ec690fca62259b5f226e2d6941a507cc61786e Signed-off-by: Yujun Zhang --- func/args_handler.py | 12 ++++++------ func/cli.py | 2 +- 2 files changed, 7 insertions(+), 7 deletions(-) (limited to 'func') diff --git a/func/args_handler.py b/func/args_handler.py index e27d37e7..59712800 100644 --- a/func/args_handler.py +++ b/func/args_handler.py @@ -14,14 +14,14 @@ from func.spawn_vm import SpawnVM from func.driver import Driver -def get_files_in_test_list(suit_name, case_type='all'): - benchmark_list = json.load(file('test_list/{0}'.format(suit_name))) +def get_files_in_test_list(suite_name, case_type='all'): + benchmark_list = json.load(file('test_list/{0}'.format(suite_name))) return reduce(add, benchmark_list.values()) \ if case_type == 'all' else benchmark_list[case_type] -def get_files_in_test_case(lab, suit_name, case_type='all'): - test_case_all = os.listdir('./test_cases/{0}/{1}'.format(lab, suit_name)) +def get_files_in_test_case(lab, suite_name, case_type='all'): + test_case_all = os.listdir('./test_cases/{0}/{1}'.format(lab, suite_name)) return test_case_all if case_type == 'all' else \ filter(lambda x: case_type in x, test_case_all) @@ -30,8 +30,8 @@ def get_benchmark_path(lab, suit, benchmark): return './test_cases/{0}/{1}/{2}'.format(lab, suit, benchmark) -def check_suit_in_test_list(suit_name): - return True if os.path.isfile('test_list/' + suit_name) else False +def check_suite_in_test_list(suite_name): + return True if os.path.isfile('test_list/' + suite_name) else False def check_lab_name(lab_name): diff --git a/func/cli.py b/func/cli.py index 833437d5..9222da51 100644 --- a/func/cli.py +++ b/func/cli.py @@ -40,7 +40,7 @@ class cli: def __init__(self, args=sys.argv[1:]): args = self._parse_args(args) - if not args_handler.check_suit_in_test_list(args.file): + if not args_handler.check_suite_in_test_list(args.file): print('\n\n ERROR: Test File Does not exist in test_list/ please enter correct file \n\n') sys.exit(1) -- cgit 1.2.3-korg