1
0
mirror of https://github.com/go-task/task.git synced 2025-06-15 00:15:10 +02:00

feat: invert call.Direct (#1459)

This commit is contained in:
Pete Davison
2024-01-11 00:32:49 +00:00
committed by GitHub
parent 07e6f5cad7
commit 42af0fc791
6 changed files with 22 additions and 22 deletions

View File

@ -1789,7 +1789,7 @@ func TestErrorCode(t *testing.T) {
}
require.NoError(t, e.Setup())
err := e.Run(context.Background(), ast.Call{Task: test.task, Direct: true})
err := e.Run(context.Background(), ast.Call{Task: test.task})
require.Error(t, err)
taskRunErr, ok := err.(*errors.TaskRunError)
assert.True(t, ok, "cannot cast returned error to *task.TaskRunError")
@ -2183,7 +2183,7 @@ func TestForce(t *testing.T) {
ForceAll: tt.forceAll,
}
require.NoError(t, e.Setup())
require.NoError(t, e.Run(context.Background(), ast.Call{Task: "task-with-dep", Direct: true}))
require.NoError(t, e.Run(context.Background(), ast.Call{Task: "task-with-dep"}))
})
}
}
@ -2238,7 +2238,7 @@ func TestFor(t *testing.T) {
Force: true,
}
require.NoError(t, e.Setup())
require.NoError(t, e.Run(context.Background(), ast.Call{Task: test.name, Direct: true}))
require.NoError(t, e.Run(context.Background(), ast.Call{Task: test.name}))
assert.Equal(t, test.expectedOutput, buff.String())
})
}