package
Version:
v0.0.0-...-eb599cc
Opens a new window with list of versions in this module.
Published: Jan 5, 2021
License: MIT
Opens a new window with license information.
Imports: 3
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
Documentation
¶
Mock provides various helpers to unit tests
NewMock sets up a new test environment
func (m *Mock) Allow(rpc RPC) *Stub
Allow sets up a stub for the RPC that allows any number of requests
ExpectN sets up a stub for the RPC that expects n matching requests
func (m *Mock) ExpectOne(rpc RPC) *Stub
ExpectOne sets up a stub for the RPC that expects one matching request
func (m *Mock) RunAssertions()
RunAssertions asserts that the expectations have been met
Stop performs cleanup and should be deferred in unit tests
RPC is an interface that svcdef request types conform to
Source Files
¶
Click to show internal directories.
Click to hide internal directories.