Versions in this module Expand all Collapse all v1 v1.6.0 Oct 15, 2025 v1.5.0 Oct 15, 2025 v1.4.0 Oct 15, 2025 v1.3.0 Oct 14, 2025 v1.1.1 Oct 13, 2025 Changes in this version + func PollUntil(ctx context.Context, interval time.Duration, condition func() bool) error + func PollUntilWithError(ctx context.Context, interval time.Duration, condition func() (bool, error)) error + func Retry(ctx context.Context, attempts int, initialDelay time.Duration, ...) error + type Assertions struct + func NewAssertions(t TestingT) *Assertions + func (a *Assertions) ContainerHealthy(containerID string, client *Client) + func (a *Assertions) ContainerRunning(containerID string, client *Client) + func (a *Assertions) Contains(haystack, needle, msg string) + func (a *Assertions) Equal(expected, actual interface{}, msg string) + func (a *Assertions) Error(err error, msg string) + func (a *Assertions) Errorf(format string, args ...interface{}) + func (a *Assertions) Eventually(condition func() bool, timeout, interval time.Duration, msg string) + func (a *Assertions) EventuallyWithContext(ctx context.Context, condition func() bool, interval time.Duration, msg string) + func (a *Assertions) Fail(msg string) + func (a *Assertions) FailNow() + func (a *Assertions) False(condition bool, msg string) + func (a *Assertions) Fatalf(format string, args ...interface{}) + func (a *Assertions) HasLeader(cluster *Cluster) + func (a *Assertions) Info(msg string) + func (a *Assertions) Len(obj interface{}, expected int, msg string) + func (a *Assertions) Log(msg string) + func (a *Assertions) Logf(format string, args ...interface{}) + func (a *Assertions) Nil(obj interface{}, msg string) + func (a *Assertions) NoError(err error, msg string) + func (a *Assertions) NodeCount(expected int, client *Client) + func (a *Assertions) NodeRole(nodeID, expectedRole string, client *Client) + func (a *Assertions) NotContains(haystack, needle, msg string) + func (a *Assertions) NotEqual(expected, actual interface{}, msg string) + func (a *Assertions) NotNil(obj interface{}, msg string) + func (a *Assertions) QuorumSize(expected int, cluster *Cluster) + func (a *Assertions) ServiceDeleted(name string, client *Client) + func (a *Assertions) ServiceExists(name string, client *Client) + func (a *Assertions) ServiceReplicas(name string, expected int, client *Client) + func (a *Assertions) ServiceRunning(name string, client *Client) + func (a *Assertions) Step(step string) + func (a *Assertions) Success(msg string) + func (a *Assertions) True(condition bool, msg string) + func (a *Assertions) Warning(msg string) + type Client struct + func NewClient(c *client.Client) *Client + func (c *Client) CreateIngress(name string, spec *IngressSpec) error + func (c *Client) CreateService(name, image string, replicas int) error + func (c *Client) CreateServiceWithEnv(name, image string, replicas int, env map[string]string) error + func (c *Client) DeleteIngress(name string) error + func (c *Client) ListIngresses() ([]*proto.Ingress, error) + type Cluster struct + Config *ClusterConfig + Managers []*Manager + Workers []*Worker + func NewCluster(config *ClusterConfig) (*Cluster, error) + func (c *Cluster) Cleanup() error + func (c *Cluster) GetLeader() (*Manager, error) + func (c *Cluster) KillManager(id string) error + func (c *Cluster) RestartManager(id string) error + func (c *Cluster) Start() error + func (c *Cluster) Stop() error + func (c *Cluster) WaitForQuorum() error + func (c *Cluster) WaitForWorkers() error + type ClusterConfig struct + DataDir string + KeepOnFailure bool + LogLevel string + ManagerVMConfig *VMConfig + NumManagers int + NumWorkers int + Runtime RuntimeType + UseLima bool + WarrenBinary string + WorkerVMConfig *VMConfig + func DefaultClusterConfig() *ClusterConfig + type IngressBackend struct + Port int + Service string + type IngressSpec struct + Backend IngressBackend + Host string + Path string + PathType string + TLS *IngressTLS + type IngressTLS struct + Enabled bool + SecretName string + type LogBuffer struct + func (lb *LogBuffer) Append(line string) + func (lb *LogBuffer) Clear() + func (lb *LogBuffer) Contains(pattern string) bool + func (lb *LogBuffer) Lines() int + func (lb *LogBuffer) Since(since time.Time) string + func (lb *LogBuffer) String() string + type Manager struct + APIAddr string + Client *Client + DataDir string + ID string + IsLeader bool + Process *Process + RaftAddr string + RawClient *client.Client + VM VM + type Process struct + Args []string + Binary string + Cancel context.CancelFunc + Ctx context.Context + Env []string + LogFile string + PID int + func NewProcess(binary string) *Process + func (p *Process) IsRunning() bool + func (p *Process) Kill() error + func (p *Process) Logs() string + func (p *Process) LogsSince(since time.Time) string + func (p *Process) Restart() error + func (p *Process) Start() error + func (p *Process) Stop() error + func (p *Process) Wait() error + func (p *Process) WaitForLog(pattern string, timeout time.Duration) error + type RuntimeType string + const RuntimeDocker + const RuntimeLima + const RuntimeLocal + type ServicePort struct + ContainerPort int + Protocol string + type ServiceSpec struct + Env map[string]string + Image string + Name string + Ports []ServicePort + Replicas int + type TestContext struct + Cancel context.CancelFunc + Ctx context.Context + T TestingT + Timeout time.Duration + type TestingT interface + Errorf func(format string, args ...interface{}) + FailNow func() + Failed func() bool + Fatalf func(format string, args ...interface{}) + Helper func() + Logf func(format string, args ...interface{}) + Name func() string + type VM interface + CopyFile func(ctx context.Context, src, dst string) error + Exec func(ctx context.Context, command string, args ...string) (string, error) + GetIP func() (string, error) + ID func() string + IsRunning func() bool + Kill func(ctx context.Context) error + Start func(ctx context.Context) error + Stop func(ctx context.Context) error + WaitForBoot func(ctx context.Context) error + type VMConfig struct + CPUs int + Disk string + Memory string + type Waiter struct + func DefaultWaiter() *Waiter + func NewWaiter(timeout, interval time.Duration) *Waiter + func (w *Waiter) WaitFor(ctx context.Context, condition func() bool, description string) error + func (w *Waiter) WaitForClusterHealthy(ctx context.Context, client *Client) error + func (w *Waiter) WaitForConditionWithRetry(ctx context.Context, condition func() (bool, error), description string) error + func (w *Waiter) WaitForContainer(ctx context.Context, client *Client, containerID string, status string) error + func (w *Waiter) WaitForContainerHealthy(ctx context.Context, client *Client, containerID string) error + func (w *Waiter) WaitForContainerRunning(ctx context.Context, client *Client, containerID string) error + func (w *Waiter) WaitForLeaderElection(ctx context.Context, cluster *Cluster) error + func (w *Waiter) WaitForManagerNodes(ctx context.Context, client *Client, count int) error + func (w *Waiter) WaitForNodeCount(ctx context.Context, client *Client, count int) error + func (w *Waiter) WaitForQuorum(ctx context.Context, cluster *Cluster) error + func (w *Waiter) WaitForReplicas(ctx context.Context, client *Client, serviceName string, count int) error + func (w *Waiter) WaitForSecret(ctx context.Context, client *Client, name string) error + func (w *Waiter) WaitForSecretDeleted(ctx context.Context, client *Client, name string) error + func (w *Waiter) WaitForServiceDeleted(ctx context.Context, client *Client, name string) error + func (w *Waiter) WaitForServiceRunning(ctx context.Context, client *Client, name string) error + func (w *Waiter) WaitForVolume(ctx context.Context, client *Client, name string) error + func (w *Waiter) WaitForVolumeDeleted(ctx context.Context, client *Client, name string) error + func (w *Waiter) WaitForWorkerNodes(ctx context.Context, client *Client, count int) error + type Worker struct + DataDir string + ID string + ManagerAddr string + Process *Process + VM VM