migratortest

package
v0.1.3 Latest Latest
Warning

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

Go to latest
Published: Jun 21, 2026 License: MIT Imports: 2 Imported by: 0

Documentation

Overview

Package migratortest provides recording test doubles for the migrator contract.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Migrator

type Migrator struct {
	MigrateCalled  bool
	RollbackCalled bool
	FreshCalled    bool
	State          *contract.Status
}

Migrator is a spy migrator that only records which operations were invoked.

func (*Migrator) Fresh

func (m *Migrator) Fresh(context.Context) error

func (*Migrator) Migrate

func (m *Migrator) Migrate(context.Context) error

func (*Migrator) Rollback

func (m *Migrator) Rollback(context.Context) error

func (*Migrator) Status

func (m *Migrator) Status(context.Context) (*contract.Status, error)

Jump to

Keyboard shortcuts

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