simulator

package
v1.20241112.540 Latest Latest
Warning

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

Go to latest
Published: Nov 11, 2024 License: 0BSD Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MigaduAPI

func MigaduAPI(t *testing.T, state *State) http.HandlerFunc

MigaduAPI returns a handler function that simulates the Migadu API.

Types

type RewriteServerModel

type RewriteServerModel struct {
	model.RewriteRule
	Destinations string `json:"destinations"`
}

type State

type State struct {
	Mailboxes  []model.Mailbox
	Aliases    []model.Alias
	Identities []model.Identity
	Rewrites   []model.RewriteRule
	StatusCode int
}

State is the optional state of the Migadu API. Use this to populate the simulator before a test.

Jump to

Keyboard shortcuts

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