MCPcopy Index your code
hub / github.com/coder/coder / newTestAPIWithUpdateEnv

Function newTestAPIWithUpdateEnv

agent/agentproc/api_test.go:126–129  ·  view source on GitHub ↗

newTestAPIWithUpdateEnv creates a new API with an optional updateEnv hook for testing environment injection.

(t *testing.T, updateEnv func([]string) ([]string, error))

Source from the content-addressed store, hash-verified

124// newTestAPIWithUpdateEnv creates a new API with an optional
125// updateEnv hook for testing environment injection.
126func newTestAPIWithUpdateEnv(t *testing.T, updateEnv func([]string) ([]string, error)) http.Handler {
127 t.Helper()
128 return newTestAPIWithOptions(t, updateEnv, nil)
129}
130
131// newTestAPIWithOptions creates a new API with optional
132// updateEnv and workingDir hooks.

Callers 1

TestStartProcessFunction · 0.85

Calls 2

newTestAPIWithOptionsFunction · 0.85
HelperMethod · 0.65

Tested by

no test coverage detected