podman

package
v1.30.0 Latest Latest
Warning

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

Go to latest
Published: Sep 21, 2026 License: Apache-2.0 Imports: 6 Imported by: ? 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: podman / tools type: test-support job: run a throwaway container for an adapter's real-counterpart test, on a free port, torn down after limits: a test helper; it skips without podman and waits for the port, not for readiness

Package podman is the shared boilerplate for the real-counterpart adapter tests (OpenBao, and lowkey-vault for the Azure backends). An adapter's only meaningful test drives its real backend, spun up here; Run publishes it on a free host port, returns that address plus a teardown, and skips the test when podman is missing so the offline gate stays green.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Run

func Run(t testing.TB, spec Spec) (addr string, teardown func())

Run starts spec's container and returns the address of spec.Port plus a teardown. It waits until that port accepts connections; the caller performs any service-specific readiness (e.g. an unseal/health check).

func RunMore added in v1.28.0

func RunMore(t testing.TB, spec Spec) (addr string, more map[int]string, teardown func())

RunMore is Run for a counterpart whose API and token endpoint listen separately: it also returns spec.More's addresses, keyed by container port.

Types

type Spec

type Spec struct {
	Image string            // image reference, e.g. ghcr.io/openbao/openbao:latest
	Port  int               // container port to publish and wait for
	More  []int             // further container ports to publish, addressed through RunMore
	Env   map[string]string // environment variables
	Args  []string          // command + args after the image
}

Spec describes a container to run for a test.

Jump to

Keyboard shortcuts

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