mirror of
https://github.com/httprunner/httprunner.git
synced 2026-05-15 04:19:28 +08:00
TestcaseParser: rename function name, bind_variables => update_binded_variables
This commit is contained in:
@@ -34,7 +34,7 @@ class Context(object):
|
||||
self.testcase_variables_mapping = copy.deepcopy(self.testset_shared_variables_mapping)
|
||||
|
||||
self.testcase_parser.bind_functions(self.testcase_functions_config)
|
||||
self.testcase_parser.bind_variables(self.testcase_variables_mapping)
|
||||
self.testcase_parser.update_binded_variables(self.testcase_variables_mapping)
|
||||
|
||||
if level == "testset":
|
||||
self.import_module_items(["ate.built_in"], "testset")
|
||||
@@ -117,7 +117,7 @@ class Context(object):
|
||||
self.testset_shared_variables_mapping[variable_name] = variable_evale_value
|
||||
|
||||
self.testcase_variables_mapping[variable_name] = variable_evale_value
|
||||
self.testcase_parser.bind_variables(self.testcase_variables_mapping)
|
||||
self.testcase_parser.update_binded_variables(self.testcase_variables_mapping)
|
||||
|
||||
def __update_context_functions_config(self, level, config_mapping):
|
||||
"""
|
||||
|
||||
@@ -330,11 +330,11 @@ def substitute_variables_with_mapping(content, mapping):
|
||||
class TestcaseParser(object):
|
||||
|
||||
def __init__(self, variables={}, functions={}, file_path=None):
|
||||
self.bind_variables(variables)
|
||||
self.update_binded_variables(variables)
|
||||
self.bind_functions(functions)
|
||||
self.file_path = file_path
|
||||
|
||||
def bind_variables(self, variables):
|
||||
def update_binded_variables(self, variables):
|
||||
""" bind variables to current testcase parser
|
||||
@param (dict) variables, variables binds mapping
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user