Package-level declarations

Types

Link copied to clipboard
abstract class ChainedCliktCommand<T>(name: String? = null) : CoreChainedCliktCommand<T>

A version of CliktCommand that returns a value from the run function, which is then passed to subcommands.

Link copied to clipboard

A version of CliktCommand that supports a suspending run function.

Link copied to clipboard

A SuspendingCliktCommand that has a default implementation of run that is a no-op.

Functions

Link copied to clipboard
fun <T> ChainedCliktCommand<T>.test(argv: Array<String>, initial: T, stdin: String = "", envvars: Map<String, String> = emptyMap(), includeSystemEnvvars: Boolean = false, ansiLevel: AnsiLevel = AnsiLevel.NONE, width: Int = 79, height: Int = 24): CliktCommandTestResult
fun <T> ChainedCliktCommand<T>.test(argv: String, initial: T, stdin: String = "", envvars: Map<String, String> = emptyMap(), includeSystemEnvvars: Boolean = false, ansiLevel: AnsiLevel = AnsiLevel.NONE, width: Int = 79, height: Int = 24): CliktCommandTestResult
fun <T> ChainedCliktCommand<T>.test(argv: List<String>, initial: T, stdin: String = "", envvars: Map<String, String> = emptyMap(), includeSystemEnvvars: Boolean = false, ansiLevel: AnsiLevel = AnsiLevel.NONE, width: Int = 79, height: Int = 24): CliktCommandTestResult
suspend fun SuspendingCliktCommand.test(argv: Array<String>, stdin: String = "", envvars: Map<String, String> = emptyMap(), includeSystemEnvvars: Boolean = false, ansiLevel: AnsiLevel = AnsiLevel.NONE, width: Int = 79, height: Int = 24, hyperlinks: Boolean = ansiLevel != AnsiLevel.NONE, outputInteractive: Boolean = ansiLevel != AnsiLevel.NONE, inputInteractive: Boolean = ansiLevel != AnsiLevel.NONE): CliktCommandTestResult
suspend fun SuspendingCliktCommand.test(argv: String, stdin: String = "", envvars: Map<String, String> = emptyMap(), includeSystemEnvvars: Boolean = false, ansiLevel: AnsiLevel = AnsiLevel.NONE, width: Int = 79, height: Int = 24, hyperlinks: Boolean = ansiLevel != AnsiLevel.NONE, outputInteractive: Boolean = ansiLevel != AnsiLevel.NONE, inputInteractive: Boolean = ansiLevel != AnsiLevel.NONE): CliktCommandTestResult
suspend fun SuspendingCliktCommand.test(argv: List<String>, stdin: String = "", envvars: Map<String, String> = emptyMap(), includeSystemEnvvars: Boolean = false, ansiLevel: AnsiLevel = AnsiLevel.NONE, width: Int = 79, height: Int = 24, hyperlinks: Boolean = ansiLevel != AnsiLevel.NONE, outputInteractive: Boolean = ansiLevel != AnsiLevel.NONE, inputInteractive: Boolean = ansiLevel != AnsiLevel.NONE): CliktCommandTestResult

Test this command, returning a result that captures the output and result status code.