testutil

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Jun 2, 2026 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewTestDB

func NewTestDB(t *testing.T) *db.DB

Types

type MockSandbox

type MockSandbox struct {
	SetupCalled bool
	Config      sandbox.SandboxConfig
	ShellCalls  []string
	CleanedUp   bool
}

func (*MockSandbox) Cleanup

func (m *MockSandbox) Cleanup() error

func (*MockSandbox) Setup

func (m *MockSandbox) Setup(cfg sandbox.SandboxConfig) error

func (*MockSandbox) Shell

func (m *MockSandbox) Shell(windowName string, cmd string) (string, error)

type TestServer

type TestServer struct {
	Server *server.Server
	Client *client.Client
}

TestServer wraps a running server for testing.

func NewTestServer

func NewTestServer(t *testing.T) *TestServer

NewTestServer starts a server with a temp UNIX socket and in-memory DB.

Jump to

Keyboard shortcuts

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