testutils

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Nov 27, 2018 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Logger

func Logger(context string) func(string, ...interface{})

Types

type Args

type Args map[string]interface{}

type Info

type Info struct {
	Called int
	Arg    Args
}

type Spy

type Spy struct {
	Done chan Info
	// contains filtered or unexported fields
}

Spy is used to inspect how many times hooks are called

func (*Spy) Args

func (s *Spy) Args() Args

func (*Spy) Called

func (s *Spy) Called() int

func (*Spy) Hook

func (s *Spy) Hook(v Args) func()

func (*Spy) HookSync

func (s *Spy) HookSync() (func(v Args) func(), chan Info)

Jump to

Keyboard shortcuts

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