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

Function requireCopilotExecutionStep

pkg/workflow/enable_api_proxy_test.go:10–26  ·  view source on GitHub ↗
(t *testing.T, steps []GitHubActionStep)

Source from the content-addressed store, hash-verified

8)
9
10func requireCopilotExecutionStep(t *testing.T, steps []GitHubActionStep) string {
11 t.Helper()
12
13 if len(steps) != 1 {
14 t.Fatalf("Expected 1 execution step, got %d", len(steps))
15 }
16
17 executionContent := strings.Join(steps[0], "\n")
18 if !strings.Contains(executionContent, "Execute GitHub Copilot CLI") {
19 t.Fatalf("Expected Copilot step to execute the CLI, got:\n%s", executionContent)
20 }
21 if !strings.Contains(executionContent, "id: agentic_execution") {
22 t.Fatalf("Expected execution step to have id 'agentic_execution', got:\n%s", executionContent)
23 }
24
25 return executionContent
26}
27
28// TestEngineAWFEnableApiProxy tests that engines with LLM gateway support
29// emit API proxy enablement in the AWF config file (new) or as --enable-api-proxy

Calls

no outgoing calls

Tested by

no test coverage detected