MCPcopy Create free account
hub / github.com/github/gh-aw / TestBuildDispatchLabelCommandCondition

Function TestBuildDispatchLabelCommandCondition

pkg/workflow/label_command_test.go:202–209  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

200}
201
202func TestBuildDispatchLabelCommandCondition(t *testing.T) {
203 condition, err := buildDispatchLabelCommandCondition([]string{"cloclo"}, []string{"issues"})
204 require.NoError(t, err)
205 rendered := condition.Render()
206 assert.NotContains(t, rendered, "github.event_name")
207 assert.Contains(t, rendered, "fromJSON(github.event.inputs.aw_context || '{}').event_type == 'issues'")
208 assert.Contains(t, rendered, "fromJSON(github.event.inputs.aw_context || '{}').trigger_label == 'cloclo'")
209}
210
211// TestLabelCommandWorkflowCompile verifies that a workflow with label_command trigger
212// compiles to a valid GitHub Actions workflow with:

Callers

nothing calls this directly

Calls 2

RenderMethod · 0.65

Tested by

no test coverage detected