Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var Module = fx.Options( fx.Provide(NewRuntime), )
Functions ¶
func WithTestEnv ¶
Types ¶
type Runtime ¶
type Runtime interface { RegisterWorkflow(w any, options workflow.RegisterOptions) RegisterActivity(a any, options activity.RegisterOptions) ExecuteWorkflow(ctx context.Context, options client.StartWorkflowOptions, workflow any, request any) (client.WorkflowRun, error) ExecuteActivity(ctx workflow.Context, activity any, request any, response any) error GetLogger(ctx workflow.Context) *zap.Logger GetMetricsHandler(ctx workflow.Context) client.MetricsHandler GetActivityLogger(ctx context.Context) *zap.Logger GetTimeSource(ctx workflow.Context) timesource.TimeSource TerminateWorkflow(ctx context.Context, workflowID string, runID string, reason string) error OnStart(ctx context.Context) error OnStop(ctx context.Context) error ListOpenWorkflows(ctx context.Context, namespace string, maxPageSize int32) (*workflowservice.ListOpenWorkflowExecutionsResponse, error) }
func NewRuntime ¶
func NewRuntime(params RuntimeParams) (Runtime, error)
type RuntimeParams ¶
type TestEnv ¶
type TestEnv struct { *testsuite.TestWorkflowEnvironment // contains filtered or unexported fields }
func NewTestActivityEnv ¶
func NewTestActivityEnv(ts WorkflowTestSuite) *TestEnv
func NewTestEnv ¶
func NewTestEnv(ts WorkflowTestSuite) *TestEnv
func (*TestEnv) BackgroundContext ¶
func (*TestEnv) IsActivityEnv ¶
type WorkflowTestSuite ¶
type WorkflowTestSuite interface { T() *testing.T NewTestWorkflowEnvironment() *testsuite.TestWorkflowEnvironment NewTestActivityEnvironment() *testsuite.TestActivityEnvironment }
Click to show internal directories.
Click to hide internal directories.