k6

package
v0.5.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 16, 2026 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client interface {
	Start(ctx context.Context, scriptContent string, upload bool, envVars map[string]string, outputWriter io.Writer) (TestRun, error)
}

func NewLocalRunnerClient

func NewLocalRunnerClient(token string) (Client, error)

type DefaultTestRun added in v0.3.0

type DefaultTestRun struct {
	*exec.Cmd
	// contains filtered or unexported fields
}

func (*DefaultTestRun) CleanupContext added in v0.3.0

func (tr *DefaultTestRun) CleanupContext()

func (*DefaultTestRun) ExecutionDuration added in v0.3.0

func (tr *DefaultTestRun) ExecutionDuration() time.Duration

func (*DefaultTestRun) ExitCode added in v0.3.0

func (tr *DefaultTestRun) ExitCode() int

func (*DefaultTestRun) Exited added in v0.3.0

func (tr *DefaultTestRun) Exited() bool

func (*DefaultTestRun) Kill added in v0.3.0

func (tr *DefaultTestRun) Kill() error

func (*DefaultTestRun) PID added in v0.3.0

func (tr *DefaultTestRun) PID() int

func (*DefaultTestRun) SetCancelFunc added in v0.3.0

func (tr *DefaultTestRun) SetCancelFunc(fn context.CancelFunc)

func (*DefaultTestRun) Start added in v0.3.0

func (tr *DefaultTestRun) Start() error

func (*DefaultTestRun) Wait added in v0.3.0

func (tr *DefaultTestRun) Wait() error

type LocalRunnerClient

type LocalRunnerClient struct {
	// contains filtered or unexported fields
}

func (*LocalRunnerClient) Start

func (c *LocalRunnerClient) Start(ctx context.Context, scriptContent string, upload bool, envVars map[string]string, outputWriter io.Writer) (TestRun, error)

type TestRun

type TestRun interface {
	Wait() error
	Kill() error
	PID() int
	Exited() bool
	ExitCode() int
	ExecutionDuration() time.Duration
	CleanupContext()
	SetCancelFunc(context.CancelFunc)
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL