e2e

package
v0.34.0 Latest Latest
Warning

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

Go to latest
Published: Jan 29, 2026 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FindRepoRoot added in v0.34.0

func FindRepoRoot(t *testing.T) string

FindRepoRoot finds the repository root using go env GOMOD.

func Run

func Run(t *testing.T, args []string, opts ...Option) (stdout, stderr string)

Run executes the neva command with the given arguments and options. It returns captured stdout and stderr separately. The working directory is os.Getwd() (relies on go test running each package with cwd at that package). Most tests can ignore stderr: `out, _ := e2e.Run(...)` Tests that need stderr (e.g., panic cases) can use: `out, stderr := e2e.Run(...)` and combine if needed.

Types

type Option added in v0.34.0

type Option func(*config)

Option configures Run behavior.

func WithCode added in v0.34.0

func WithCode(code int) Option

WithCode sets the expected exit code (default is 0).

func WithDir added in v0.34.0

func WithDir(wd string) Option

WithDir sets the working directory for the command execution.

func WithStdin added in v0.34.0

func WithStdin(stdin string) Option

WithStdin sets stdin input for the command.

Jump to

Keyboard shortcuts

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