mock

package
v0.0.0-...-f574766 Latest Latest
Warning

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

Go to latest
Published: Apr 15, 2020 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Mock

type Mock struct {
	ReceivedValidations []ReceivedValidation
	ValidationResults   []ValidationResult
}

func New

func New() *Mock

func (*Mock) AddValidationResult

func (m *Mock) AddValidationResult(apiKey string, err error)

func (*Mock) Validate

func (m *Mock) Validate(escherRequest request.Interface, db keydb.KeyDB, mandatoryHeaders []string) (string, error)

type ReceivedValidation

type ReceivedValidation struct {
	Request          request.Interface
	KeyDB            keydb.KeyDB
	MandatoryHeaders []string
}

type ReceivedValidations

type ReceivedValidations []ReceivedValidation

type ValidationResult

type ValidationResult struct {
	ApiKey string
	Error  error
}

type ValidationResults

type ValidationResults []ValidationResult

Jump to

Keyboard shortcuts

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