Skip to content

Commit 41a5263

Browse files
Mikołaj Baranowskishreyassrivatsan
authored andcommitted
Make test suite respond with a typed error for unknown workflow execution (#758)
1 parent bd283b3 commit 41a5263

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

internal/internal_workflow_testsuite.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1638,7 +1638,7 @@ func (env *testWorkflowEnvironmentImpl) SignalExternalWorkflow(domainName, workf
16381638
childEnv := childHandle.env
16391639
if childEnv.isTestCompleted {
16401640
// child already completed (NOTE: we have only one failed cause now)
1641-
err := fmt.Errorf("signal external workflow failed, %v", shared.SignalExternalWorkflowExecutionFailedCauseUnknownExternalWorkflowExecution)
1641+
err := newUnknownExternalWorkflowExecutionError()
16421642
callback(nil, err)
16431643
} else {
16441644
childEnv.signalHandler(signalName, input)
@@ -1650,7 +1650,7 @@ func (env *testWorkflowEnvironmentImpl) SignalExternalWorkflow(domainName, workf
16501650

16511651
// here we signal a child workflow but we cannot find it
16521652
if childWorkflowOnly {
1653-
err := fmt.Errorf("signal external workflow failed, %v", shared.SignalExternalWorkflowExecutionFailedCauseUnknownExternalWorkflowExecution)
1653+
err := newUnknownExternalWorkflowExecutionError()
16541654
callback(nil, err)
16551655
return
16561656
}

0 commit comments

Comments
 (0)