telemetrytest

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Oct 9, 2026 License: MIT Imports: 5 Imported by: 0

Documentation

Overview

Package telemetrytest provides runner-independent conformance cases for Go telemetry adapters, ported from Pi's telemetry/testing entry point.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AdapterFixture

type AdapterFixture struct {
	Context  telemetry.Context
	GetSpans func() ([]telemetry.RecordedSpan, error)
	Close    func() error
}

AdapterFixture owns one isolated recorder and its cleanup. GetSpans returns normalized snapshots in admission order. Close may be nil for in-memory use.

type ConformanceCase

type ConformanceCase struct {
	Group string
	Name  string
	Run   func() error
}

func CreateAdapterConformance

func CreateAdapterConformance(factory func() (*AdapterFixture, error)) []ConformanceCase

CreateAdapterConformance creates a fresh fixture for each invocation of Run. No testing framework or global state is required. The case names correspond to Pi's original suite. Error returns/gated goroutines replace Promise rejection/settlement; unsupported Go attributes replace unreadable JS proxies. SetStatusFrom readers model throwing status property access in Go. A supplemental source-verified case covers readable status normalization.

Jump to

Keyboard shortcuts

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