Skip to main content
Version: Next

createMockActionContext()

Home > @backstage/plugin-scaffolder-node-test-utils > createMockActionContext

A utility method to create a mock action context for scaffolder actions.

Signature:

createMockActionContext: <TActionInput extends JsonObject = JsonObject, TActionOutput extends JsonObject = JsonObject>(options?: Partial<ActionContext<TActionInput, TActionOutput>> | undefined) => ActionContext<TActionInput, TActionOutput>

Parameters

Parameter

Type

Description

options

Partial<ActionContext<TActionInput, TActionOutput>> | undefined

(Optional) optional parameters to override default mock context

**Returns:**

ActionContext<TActionInput, TActionOutput>