Run tasks directly with language-independent project tools

This commit is contained in:
2026-10-09 01:48:46 +01:00
parent 998b0941d3
commit ed93d055bf
23 changed files with 170 additions and 156 deletions
+4 -4
View File
@@ -41,7 +41,7 @@ func TestCLIPickerAndMultilinePrompt(t *testing.T) {
m.runPrompt.SetValue("line one\nline two")
updated, _ = m.updateRunForm(tea.KeyMsg{Type: tea.KeyCtrlS})
m = updated.(Model)
if m.runForm != 2 || m.runTask != "line one\nline two" {
if m.runForm != 0 || !m.runOpen || m.runTask != "line one\nline two" {
t.Fatal("multiline prompt lost")
}
}
@@ -61,12 +61,12 @@ func TestDashboardRunUsesInvocationDirectory(t *testing.T) {
}
}
func TestCLISuppliedArgumentsStillRequireConfirmation(t *testing.T) {
func TestCLISuppliedArgumentsStartWithoutConfirmation(t *testing.T) {
m := NewRun(context.Background(), "", RunOptions{Pipeline: "test", Prompt: "task", Workspace: "/repos/a"})
m.detail = &protocol.PipelineDetail{PipelineSummary: protocol.PipelineSummary{ID: 1, Name: "test", Version: 1}}
updated, _ := m.configureCLIRun()
m = updated.(Model)
if m.runForm != 3 || m.runOpen || m.runTask != "task" || m.runWorkspace != "/repos/a" {
t.Fatal("arguments skipped approval or lost repository")
if m.runForm != 0 || !m.runOpen || m.runTask != "task" || m.runWorkspace != "/repos/a" {
t.Fatal("supplied task did not start immediately or lost repository")
}
}