testrelaynative

package
v0.1.6 Latest Latest
Warning

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

Go to latest
Published: Nov 26, 2026 License: AGPL-3.0 Imports: 19 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package testrelaynative hosts the native Rust relay for Go correctness suites.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Build

func Build(ctx context.Context, repositoryRoot, directory string) (string, error)

Build prepares a suite-local executable. Callers own the directory and invoke it once per suite, before starting any scenario deadline.

func ValidateListenerAddress

func ValidateListenerAddress(address string) error

ValidateListenerAddress also confines test proxies to an actual loopback port.

Types

type Fixture

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

Fixture retains durable state and endpoint identity across sequential starts. Each scenario supplies its own temporary directory; the process owner is shared independently so preparing another relay never rebuilds its supervisor.

func NewFixture

func NewFixture(stateDirectory, publicEndpoint string) *Fixture

func (*Fixture) Database

func (fixture *Fixture) Database() string

func (*Fixture) Start

func (fixture *Fixture) Start(ctx context.Context, owner processStarter, launch Launch) (*Host, error)

func (*Fixture) TrustIssuer added in v0.1.5

func (fixture *Fixture) TrustIssuer(root, certificate string)

TrustIssuer configures the same offline admission check an official relay uses.

type Host

type Host struct {
	Ready Readiness
	// contains filtered or unexported fields
}

func (*Host) Close

func (host *Host) Close(ctx context.Context) error

func (*Host) Diagnostic

func (host *Host) Diagnostic() string

func (*Host) Stderr

func (host *Host) Stderr() testprocess.OutputSnapshot

func (*Host) Stdout

func (host *Host) Stdout() testprocess.OutputSnapshot

type Launch

type Launch struct {
	Executable       string
	WorkingDirectory string
	Identity         testrun.Identity
}

type Readiness

type Readiness struct {
	Address  string `json:"address"`
	Endpoint string `json:"endpoint"`
	BaseURL  string `json:"-"`
}

Jump to

Keyboard shortcuts

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