Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Verify ¶
Verify exercises the public agent-workflow relation through one installed CLI carrier. Command owners provide exact expectations; adapters own only process execution.
func VerifyProcess ¶
func VerifyProcess(ctx context.Context, carrier ProcessCarrier) error
VerifyProcess applies Verify to one installed process carrier.
Types ¶
type Invocation ¶
type Invocation struct {
Args []string
Input []byte
StdinClass StdinClass
}
Invocation is one immutable installed-carrier request.
type ProcessCarrier ¶
type ProcessCarrier struct {
Directory string
Executable string
Prefix []string
Environment []string
}
ProcessCarrier identifies one installed executable and any fixed argv prefix.
type ProcessOutputLimits ¶ added in v0.7.0
ProcessOutputLimits bounds the memory retained from one process invocation. Both values must be positive and no greater than the package hard limit.
type Result ¶
Result is the observable process contract for one installed CLI invocation.
func RunProcess ¶
func RunProcess(ctx context.Context, carrier ProcessCarrier, invocation Invocation) (Result, error)
RunProcess executes one bounded carrier invocation and terminates its whole process group before returning on every post-start path.
func RunProcessWithOutputLimits ¶ added in v0.7.0
func RunProcessWithOutputLimits(ctx context.Context, carrier ProcessCarrier, invocation Invocation, limits ProcessOutputLimits) (Result, error)
RunProcessWithOutputLimits executes one invocation with caller-selected, package-bounded stdout and stderr limits.
type Runner ¶
type Runner func(context.Context, Invocation) (Result, error)
Runner invokes one installed carrier under the supplied lifecycle context.
type StdinClass ¶
type StdinClass uint8
StdinClass declares whether an invocation owns stdin bytes or must not read stdin at all.
const ( StdinBytes StdinClass = iota StdinMustRemainUnread )