Documentation
¶
Overview ¶
Package consoletest wires an *iostreams.IOStreams to a real terminal emulator (via ugh) so tests can drive interactive prompts with actual keystrokes instead of pre-canned values. It is kept dependency-light (no internal/api) so packages that internal/api itself depends on, such as internal/oauth2, can use it in tests without an import cycle; cmdtest delegates to it for the same helper.
Index ¶
Constants ¶
View Source
const ( Width = 120 Height = 40 )
Variables ¶
This section is empty.
Functions ¶
func IOStreamsWithConsole ¶
func IOStreamsWithConsole(t *testing.T, console *ugh.Console) (*iostreams.IOStreams, context.CancelFunc)
IOStreamsWithConsole wires an IOStreams to a ugh console driving a real huh form/prompt over an emulated terminal.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.