cmdtest

package
v0.30.5 Latest Latest
Warning

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

Go to latest
Published: Jun 10, 2023 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Overview

Package cmdtest provides test utilities to assert the output of CLI commands

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AssertReadersContent

func AssertReadersContent(t testing.TB, noBlanks bool, expected, actual io.Reader) bool

AssertReadersContent compares the contents from io.Readers, optionally stripping blanks

func CatchStdOut

func CatchStdOut(t testing.TB, runnable func() error) ([]byte, error)

CatchStdOut captures the standard output from a runnable function. You shouln't run this in parallel.

Types

This section is empty.

Jump to

Keyboard shortcuts

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