Discover Packages
github.com/ibiscum/Go-Programming-Cookbook-Second-Edition
chapter09
internal
mocking
package
Version:
v0.0.0-...-891ad17
Opens a new window with list of versions in this module.
Published: Dec 22, 2024
License: MIT
Opens a new window with license information.
Imports: 2
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
Documentation
Documentation
¶
type DoStuffer interface {
DoStuff(input string ) error
}
DoStuffer is a simple interface
Restorer holds a function that can be used
to restore some previous state.
func Patch(dest, value interface{}) Restorer
Patch sets the value pointed to by the given destination to
the given value, and returns a function to restore it to its
original value. The value must be assignable to the element type
of the destination.
Restore restores some previous state.
Source Files
¶
Click to show internal directories.
Click to hide internal directories.