Feat/environment variables in workflow (#6515)

Co-authored-by: JzoNg <jzongcode@gmail.com>
This commit is contained in:
-LAN-
2024-07-22 15:29:39 +08:00
committed by GitHub
parent 87d583f454
commit 5e6fc58db3
146 changed files with 2486 additions and 746 deletions

View File

@@ -6,8 +6,8 @@ from models.workflow import WorkflowNodeExecutionStatus
def test_tool_variable_invoke():
pool = VariablePool(system_variables={}, user_inputs={})
pool.append_variable(node_id='1', variable_key_list=['123', 'args1'], value='1+1')
pool = VariablePool(system_variables={}, user_inputs={}, environment_variables=[])
pool.add(['1', '123', 'args1'], '1+1')
node = ToolNode(
tenant_id='1',
@@ -45,8 +45,8 @@ def test_tool_variable_invoke():
assert result.outputs['files'] == []
def test_tool_mixed_invoke():
pool = VariablePool(system_variables={}, user_inputs={})
pool.append_variable(node_id='1', variable_key_list=['args1'], value='1+1')
pool = VariablePool(system_variables={}, user_inputs={}, environment_variables=[])
pool.add(['1', 'args1'], '1+1')
node = ToolNode(
tenant_id='1',