Versions in this module Expand all Collapse all v1 v1.0.1 Sep 26, 2026 v1.0.0 Jul 23, 2026 Changes in this version + var ErrDuplicateStepName = errors.New("seed: duplicate step name") + var ErrEmptyStepName = errors.New("seed: step name must not be empty") + var ErrNilApply = errors.New("seed: step Apply must not be nil") + func Count(ctx context.Context, db Executor, query string, args ...any) (int, error) + type Executor interface + ExecContext func(ctx context.Context, query string, args ...any) (sql.Result, error) + QueryRowContext func(ctx context.Context, query string, args ...any) *sql.Row + type Option func(*options) + func WithLogger(l *slog.Logger) Option + type Phase string + const PhaseApply + const PhaseAssert + type RowSpec struct + Apply string + ApplyArgs []any + Count string + CountArgs []any + Name string + WantAtLeast int + func (s RowSpec) Step() Step[Executor] + type Runner struct + func New[T any](target T, opts ...Option) *Runner[T] + func (r *Runner[T]) Add(steps ...Step[T]) *Runner[T] + func (r *Runner[T]) Run(ctx context.Context) error + type Step struct + Apply func(ctx context.Context, target T) error + Assert func(ctx context.Context, target T) error + Name string + type StepError struct + Err error + Phase Phase + Step string + func (e *StepError) Error() string + func (e *StepError) Unwrap() error