StdoutMatches(String) Method

Definition

Assembly CliInvoke.dll

Creates a validator that ensures the buffered process result's standard output matches the supplied regular expression. Results that do not expose buffered standard output text (non-buffered or null results) fail the rule, as dictated by the inner rule.

public static IProcessResultValidator<ProcessResult> StdoutMatches(string regex)

Parameters

regex
String

The regular expression pattern to evaluate against StandardOutput.

Returns

IProcessResultValidator<TProcessResult>
A validator enforcing a standard output match.