summaryrefslogtreecommitdiff
path: root/internal/taskproxy
diff options
context:
space:
mode:
Diffstat (limited to 'internal/taskproxy')
-rw-r--r--internal/taskproxy/run_test.go12
1 files changed, 6 insertions, 6 deletions
diff --git a/internal/taskproxy/run_test.go b/internal/taskproxy/run_test.go
index 15c5fbb..2414d6a 100644
--- a/internal/taskproxy/run_test.go
+++ b/internal/taskproxy/run_test.go
@@ -15,7 +15,7 @@ func TestRunnerRun_InjectsProjectFilterAndAgentTag(t *testing.T) {
var gotName string
var gotArgs []string
runner := Runner{
- CommandName: "ask",
+ CommandName: "do",
findTaskBinary: func() (string, error) { return "/usr/bin/task", nil },
detectRepoRoot: func(context.Context) (string, error) { return "/tmp/work/hexai", nil },
runCommand: func(_ context.Context, name string, args []string, stdin io.Reader, stdout, stderr io.Writer) error {
@@ -43,7 +43,7 @@ func TestRunnerRun_InjectsProjectFilterAndAgentTag(t *testing.T) {
func TestRunnerRun_OutsideGitRepo_IsActionable(t *testing.T) {
runner := Runner{
- CommandName: "ask",
+ CommandName: "do",
findTaskBinary: func() (string, error) { return "/usr/bin/task", nil },
detectRepoRoot: func(context.Context) (string, error) { return "", errors.New("git failed") },
runCommand: func(context.Context, string, []string, io.Reader, io.Writer, io.Writer) error {
@@ -63,7 +63,7 @@ func TestRunnerRun_OutsideGitRepo_IsActionable(t *testing.T) {
func TestRunnerRun_PreservesTaskwarriorExitCode(t *testing.T) {
runner := Runner{
- CommandName: "ask",
+ CommandName: "do",
findTaskBinary: func() (string, error) { return "/usr/bin/task", nil },
detectRepoRoot: func(context.Context) (string, error) { return "/tmp/work/hexai", nil },
runCommand: func(context.Context, string, []string, io.Reader, io.Writer, io.Writer) error {
@@ -84,7 +84,7 @@ func TestRunnerRun_PreservesStdoutAndStderr(t *testing.T) {
var stdout bytes.Buffer
var stderr bytes.Buffer
runner := Runner{
- CommandName: "ask",
+ CommandName: "do",
findTaskBinary: func() (string, error) { return "/usr/bin/task", nil },
detectRepoRoot: func(context.Context) (string, error) { return "/tmp/work/hexai", nil },
runCommand: func(_ context.Context, name string, args []string, stdin io.Reader, out, errOut io.Writer) error {
@@ -111,7 +111,7 @@ func TestRunnerRun_PreservesStdoutAndStderr(t *testing.T) {
func TestRunnerRun_TaskLookupFailure_IsActionable(t *testing.T) {
runner := Runner{
- CommandName: "ask",
+ CommandName: "do",
findTaskBinary: func() (string, error) { return "", errors.New("not found") },
}
@@ -126,7 +126,7 @@ func TestRunnerRun_TaskLookupFailure_IsActionable(t *testing.T) {
func TestRunnerRun_EmptyRepoName_IsActionable(t *testing.T) {
runner := Runner{
- CommandName: "ask",
+ CommandName: "do",
findTaskBinary: func() (string, error) { return "/usr/bin/task", nil },
detectRepoRoot: func(context.Context) (string, error) { return "/", nil },
}