conformance

package
v0.8.3 Latest Latest
Warning

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

Go to latest
Published: Sep 1, 2026 License: MIT Imports: 10 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 conformance provides reusable runner protocol state-machine qualification.

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrReorderedMessage   = errors.New("SecondBox conformance reordered runner message")
	ErrInactiveConnection = errors.New("SecondBox conformance inactive runner connection")
)

Functions

func DefaultSessionFactory

func DefaultSessionFactory(connectionID string) *runnercontrol.Session

DefaultSessionFactory returns the v1 evidence-enabled control-plane session.

func RunRunnerConformanceSuite

func RunRunnerConformanceSuite(t *testing.T, factory BoundaryFactory)

RunRunnerConformanceSuite qualifies every Task 4 runner lifecycle behavior.

func RunSessionSuite

func RunSessionSuite(
	t *testing.T,
	factory func(connectionID string) *runnercontrol.Session,
)

RunSessionSuite qualifies negotiation, registration, duplicate, reorder, and reconnect behavior.

Types

type Boundary

Boundary exposes the durable control-plane behavior qualified by the reusable suite.

type BoundaryFactory

type BoundaryFactory func(*testing.T, time.Time) Boundary

BoundaryFactory creates isolated durable state for one conformance case.

type FakeRunner

type FakeRunner struct {
	RunnerID     string
	PoolName     string
	ConnectionID string
	// contains filtered or unexported fields
}

FakeRunner produces canonical runner frames with stable identity and connection-local ordering.

func NewFakeRunner

func NewFakeRunner(runnerID, poolName, connectionID string) *FakeRunner

func (*FakeRunner) AssignmentReady

func (runner *FakeRunner) AssignmentReady(
	fence *runnerv1.AssignmentFence,
) *runnerv1.RunnerToControlPlane

func (*FakeRunner) Heartbeat

func (runner *FakeRunner) Heartbeat(phase runnerv1.DrainPhase) *runnerv1.RunnerToControlPlane

func (*FakeRunner) Hello

func (runner *FakeRunner) Hello(minimum, maximum uint32) *runnerv1.RunnerToControlPlane

func (*FakeRunner) Reconnect

func (runner *FakeRunner) Reconnect(connectionID string)

func (*FakeRunner) Registration

func (runner *FakeRunner) Registration() *runnerv1.RunnerToControlPlane

func (*FakeRunner) ReorderedAssignmentReady

func (runner *FakeRunner) ReorderedAssignmentReady(
	fence *runnerv1.AssignmentFence,
	sequence uint64,
) *runnerv1.RunnerToControlPlane

func (*FakeRunner) ReplayLast

func (runner *FakeRunner) ReplayLast() (*runnerv1.RunnerToControlPlane, error)

type Outcome

type Outcome string
const (
	OutcomeRegistration Outcome = "registration"
	OutcomeHeartbeat    Outcome = "heartbeat"
	OutcomeAssignment   Outcome = "assignment"
	OutcomeDuplicate    Outcome = "duplicate"
)

type Snapshot

type Snapshot struct {
	RunnerState        string
	DrainPhase         string
	VCPUCount          int64
	MemoryBytes        int64
	DiskBytes          int64
	Instances          int64
	Operations         int64
	ActiveConnectionID string
	AssignmentState    string
	MayReassign        bool
}

Snapshot is bounded durable evidence used by cross-implementation assertions.

Jump to

Keyboard shortcuts

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