Documentation
¶
Overview ¶
Package test provides test utilities for command types.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CommandSuite ¶
type CommandSuite[T command.Command] struct { suite.Suite Cmd T // contains filtered or unexported fields }
CommandSuite is a testify test suite for commands.
func NewCommandSuite ¶
func NewCommandSuite[T command.Command](cmd T) CommandSuite[T]
Create a new NewCommandSuite for the given command interface.
func (*CommandSuite[T]) RequireResultFail ¶
func (s *CommandSuite[T]) RequireResultFail(msg string)
Assert the command returned an error that contains the provided message.
func (*CommandSuite[T]) RequireResultPass ¶
func (s *CommandSuite[T]) RequireResultPass()
Assert that the command returned no error.
func (*CommandSuite[T]) RunCommand ¶
func (s *CommandSuite[T]) RunCommand(args ...string)
Run the command with the provided arguments and cache the result.
Click to show internal directories.
Click to hide internal directories.