testutil

package
v0.1.0-rc.39 Latest Latest
Warning

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

Go to latest
Published: Oct 3, 2026 License: MIT Imports: 32 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsolatedPublishingTest

func IsolatedPublishingTest(t *testing.T) bool

IsolatedPublishingTest runs a command regression in its own test process so its private TLS roots cannot affect other tests or the machine's trust store. the caller returns immediately when this returns false.

func NewDisposablePostgresDatabaseURL

func NewDisposablePostgresDatabaseURL(t testing.TB, suffix string) string

NewDisposablePostgresDatabaseURL creates a uniquely named PostgreSQL database and drops it, including any remaining connections, during cleanup.

func PostgresURL

func PostgresURL(t testing.TB) string

PostgresURL returns the PostgreSQL administration URL for PostgreSQL-backed tests.

func RequireTestTier

func RequireTestTier(t testing.TB, required TestTier)

RequireTestTier skips a test unless its suite is selected.

Types

type PublishingFixture

type PublishingFixture struct {
	URL         string
	CAFile      string
	AccessToken string
	LoginToken  string
	Namespace   string
}

PublishingFixture supplies local control/authority responses and real TLS/yamux publisher connections. it drives the unmodified command and publisher implementations without PostgreSQL, DNS, ACME, or paid resources.

func NewPublishingFixture

func NewPublishingFixture(t *testing.T, hooks PublishingHooks) *PublishingFixture

type PublishingHooks

type PublishingHooks struct {
	Ready func(context.Context, controlv1.PublishRunSetup) error
	Close func(controlv1.PublishRunSetup) error
}

type TestTier

type TestTier string

TestTier identifies an opt-in test suite.

const (
	TestTierRoutine      TestTier = "routine"
	TestTierIntegration  TestTier = "integration"
	TestTierBinary       TestTier = "binary"
	TestTierDNS          TestTier = "dns"
	TestTierRoute53      TestTier = "route53"
	TestTierDatabaseLoad TestTier = "database-load"
	TestTierRuntimeLoad  TestTier = "runtime-load"
)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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