From 1d8fd2592a09658a2ef6af104e4ce413060a6417 Mon Sep 17 00:00:00 2001 From: Snarr Date: Wed, 27 Nov 2024 14:59:50 -0500 Subject: [PATCH] Add ParentThread to WfRunVariables in tests --- sdk-python/tests/test_workflow.py | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/sdk-python/tests/test_workflow.py b/sdk-python/tests/test_workflow.py index 35e8a72cd..d1b65d467 100644 --- a/sdk-python/tests/test_workflow.py +++ b/sdk-python/tests/test_workflow.py @@ -286,7 +286,7 @@ class MyClass: def if_condition(self, thread: WorkflowThread) -> None: thread.mutate( WfRunVariable( - variable_name="variable-1", variable_type=VariableType.INT, parent=None + variable_name="variable-1", variable_type=VariableType.INT, parent=thread ), VariableMutationType.ASSIGN, 1, @@ -294,7 +294,7 @@ def if_condition(self, thread: WorkflowThread) -> None: thread.execute("task-a") thread.mutate( WfRunVariable( - variable_name="variable-3", variable_type=VariableType.INT, parent=None + variable_name="variable-3", variable_type=VariableType.INT, parent=thread ), VariableMutationType.ASSIGN, 3, @@ -304,7 +304,7 @@ def if_condition(self, thread: WorkflowThread) -> None: def else_condition(self, thread: WorkflowThread) -> None: thread.mutate( WfRunVariable( - variable_name="variable-2", variable_type=VariableType.INT, parent=None + variable_name="variable-2", variable_type=VariableType.INT, parent=thread ), VariableMutationType.ASSIGN, 2, @@ -313,7 +313,7 @@ def else_condition(self, thread: WorkflowThread) -> None: thread.execute("task-d") thread.mutate( WfRunVariable( - variable_name="variable-4", variable_type=VariableType.INT, parent=None + variable_name="variable-4", variable_type=VariableType.INT, parent=thread ), VariableMutationType.ASSIGN, 4, @@ -436,7 +436,7 @@ class MyClass: def if_condition(self, thread: WorkflowThread) -> None: thread.mutate( WfRunVariable( - variable_name="variable-1", variable_type=VariableType.INT, parent=None + variable_name="variable-1", variable_type=VariableType.INT, parent=thread ), VariableMutationType.ASSIGN, 1, @@ -445,7 +445,7 @@ def if_condition(self, thread: WorkflowThread) -> None: def else_condition(self, thread: WorkflowThread) -> None: thread.mutate( WfRunVariable( - variable_name="variable-2", variable_type=VariableType.INT, parent=None + variable_name="variable-2", variable_type=VariableType.INT, parent=thread ), VariableMutationType.ASSIGN, 2, @@ -530,7 +530,7 @@ class MyClass: def if_condition(self, thread: WorkflowThread) -> None: thread.mutate( WfRunVariable( - variable_name="variable-2", variable_type=VariableType.INT, parent=None + variable_name="variable-2", variable_type=VariableType.INT, parent=thread ), VariableMutationType.ASSIGN, 2, @@ -539,7 +539,7 @@ def if_condition(self, thread: WorkflowThread) -> None: def my_entrypoint(self, thread: WorkflowThread) -> None: thread.mutate( WfRunVariable( - variable_name="variable-1", variable_type=VariableType.INT, parent=None + variable_name="variable-1", variable_type=VariableType.INT, parent=thread ), VariableMutationType.ASSIGN, 1, @@ -549,7 +549,7 @@ def my_entrypoint(self, thread: WorkflowThread) -> None: ) thread.mutate( WfRunVariable( - variable_name="variable-3", variable_type=VariableType.INT, parent=None + variable_name="variable-3", variable_type=VariableType.INT, parent=thread ), VariableMutationType.ASSIGN, 3, @@ -741,7 +741,7 @@ class MyClass: def my_condition(self, thread: WorkflowThread) -> None: thread.mutate( WfRunVariable( - variable_name="variable-1", variable_type=VariableType.INT, parent=None + variable_name="variable-1", variable_type=VariableType.INT, parent=thread ), VariableMutationType.ASSIGN, 1, @@ -749,7 +749,7 @@ def my_condition(self, thread: WorkflowThread) -> None: thread.execute("my-task") thread.mutate( WfRunVariable( - variable_name="variable-2", variable_type=VariableType.INT, parent=None + variable_name="variable-2", variable_type=VariableType.INT, parent=thread ), VariableMutationType.ASSIGN, 2,