MCPcopy
hub / github.com/nektos/act / TestGraphWithMissing

Function TestGraphWithMissing

pkg/runner/runner_test.go:106–121  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

104}
105
106func TestGraphWithMissing(t *testing.T) {
107 planner, err := model.NewWorkflowPlanner("testdata/issue-1595/missing.yml", true, false)
108 assert.NoError(t, err)
109
110 out := log.StandardLogger().Out
111 var buf bytes.Buffer
112 log.SetOutput(&buf)
113 log.SetLevel(log.DebugLevel)
114
115 plan, err := planner.PlanEvent("push")
116 assert.NotNil(t, plan)
117 assert.Equal(t, 0, len(plan.Stages))
118 assert.EqualError(t, err, "unable to build dependency graph for missing (missing.yml)")
119 assert.Contains(t, buf.String(), "unable to build dependency graph for missing (missing.yml)")
120 log.SetOutput(out)
121}
122
123func TestGraphWithSomeMissing(t *testing.T) {
124 log.SetLevel(log.DebugLevel)

Callers

nothing calls this directly

Calls 3

PlanEventMethod · 0.95
NewWorkflowPlannerFunction · 0.92
StringMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…