portsfake

package
v0.0.1-alpha.2 Latest Latest
Warning

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

Go to latest
Published: Jul 25, 2026 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Overview

Package portsfake provides a scripted Provider for tests and for proving the agent loop without any network access or API key (change 0018; formerly provider.Fake in internal/provider/fake.go). It plays back a fixed script of Events per call, in order — one script entry per Stream call. The call counter is atomic: a single Fake may be shared across concurrent goroutines (e.g. subagent fanout).

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Fake

type Fake struct {
	Scripts [][]ports.Event // Scripts[i] is played on the i-th call to Stream
	// contains filtered or unexported fields
}

Fake is a deterministic, in-memory ports.Provider for tests.

func (*Fake) Stream

func (f *Fake) Stream(ctx context.Context, _ ports.Request) (<-chan ports.Event, error)

Jump to

Keyboard shortcuts

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