core

package
v0.1.0-rc.1 Latest Latest
Warning

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

Go to latest
Published: Oct 1, 2026 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CertifyCore

func CertifyCore(ctx context.Context, h CoreHarness) (semantic.Certification, error)

CertifyCore selects and records scenarios for one canonical-core harness.

func RunSemanticInvariantSuite

func RunSemanticInvariantSuite(h SemanticInvariantHooks) error

RunSemanticInvariantSuite exercises the complete canonical semantic boundary. It intentionally validates presence-bearing projectors, transport admission, frozen failover obligations, output commitment, and terminal sequence rules.

Types

type CoreHarness

type CoreHarness interface {
	Subject() semantic.SubjectDescriptor
	Derivation(ctx context.Context) (RequirementDerivationView, error)
}

CoreHarness provides test interfaces for canonical-core certification.

type RequirementDerivationView

type RequirementDerivationView interface {
	DeriveRequirements(call *lipapi.Call) (lipapi.ProtocolRequirements, error)
	MatchRequirements(reqs lipapi.ProtocolRequirements, caps []lipapi.Capability) bool
	Probe(ctx context.Context, scenario semantic.ScenarioDescriptor) (semantic.ExecutionEvidence, error)
}

RequirementDerivationView tests canonical core requirement derivation and matching without real providers.

type SemanticInvariantHooks

type SemanticInvariantHooks struct {
	Derive        func(lipapi.Call) lipapi.ProtocolRequirements
	Match         func(lipapi.ProtocolRequirements, lipapi.ProtocolRequirements) bool
	ProjectItems  func(lipapi.Call, lipapi.LegacyProjectionTarget) (lipapi.LegacyProjectionResult, error)
	ProjectLegacy func(lipapi.Call, lipapi.OrderedItemProjectionTarget) ([]lipapi.Item, lipapi.ProtocolRequirements, error)
	Admit         func(lipapi.CandidateAdmissionInput) lipapi.CandidateAdmissionResult
	Validate      func([]lipapi.Event) error
	OutputPolicy  func(committed, retry bool) error
	StickyCleanup func(affinityID string, admitted bool) bool
}

SemanticInvariantHooks is the dependency-neutral seam used by the core TCK. The default hooks call canonical lipapi/core operations; tests can replace one hook with a mutation double and prove that the corresponding invariant turns RED. No frontend or backend adapter is involved in this suite.

func DefaultSemanticInvariantHooks

func DefaultSemanticInvariantHooks() SemanticInvariantHooks

Jump to

Keyboard shortcuts

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