diff --git a/psalm-baseline.xml b/psalm-baseline.xml index 298b54e1..73bbf9d6 100644 --- a/psalm-baseline.xml +++ b/psalm-baseline.xml @@ -428,7 +428,6 @@ getFailure()]]> getResult()]]> workflowType]]> - workflowType]]> getQueryResult()]]> execution]]> execution]]> diff --git a/src/Internal/Client/ResponseToResultMapper.php b/src/Internal/Client/ResponseToResultMapper.php index cad78996..1ad89104 100644 --- a/src/Internal/Client/ResponseToResultMapper.php +++ b/src/Internal/Client/ResponseToResultMapper.php @@ -25,7 +25,7 @@ public function __construct( public function mapUpdateWorkflowResponse( UpdateWorkflowExecutionResponse $result, string $updateName, - string $workflowType, + ?string $workflowType, WorkflowExecution $workflowExecution, ): StartUpdateOutput { $outcome = $result->getOutcome(); diff --git a/tests/Acceptance/Extra/Update/UntypedStubTest.php b/tests/Acceptance/Extra/Update/UntypedStubTest.php index f43e7c81..ef0daee6 100644 --- a/tests/Acceptance/Extra/Update/UntypedStubTest.php +++ b/tests/Acceptance/Extra/Update/UntypedStubTest.php @@ -68,6 +68,19 @@ public function fetchResultWithTimeout( $this->assertSame(['key' => null], (array)$result, 'Workflow result contains resolved value'); } + #[Test] + public function useClientRunningWorkflowStub( + #[Stub('Extra_Update_UntypedStub')] WorkflowStubInterface $stub, + WorkflowClientInterface $client, + ): void { + $untyped = $client->newUntypedRunningWorkflowStub( + $stub->getExecution()->getID(), + $stub->getExecution()->getRunID(), + ); + + $this->fetchResolvedResultAfterWorkflowCompleted($untyped); + } + #[Test] public function handleUnknownUpdate( #[Stub('Extra_Update_UntypedStub')] WorkflowStubInterface $stub,