AbstractProtectedassertAssert a boolean condition.
The boolean condition to assert.
The assertion description.
ProtectedassertAssert that a directory exists.
The directory path to check.
Optionalmessage: stringOptional custom assertion message.
ProtectedassertProtectedassertAssert that a command failed with an error matching the pattern.
The command result to check.
Optionalpattern: string | RegExpOptional regex or string pattern to match against output.
Optionalmessage: stringOptional custom assertion message.
ProtectedassertAssert that a file exists and optionally matches content.
The file path to check.
OptionalcontentPattern: string | RegExpOptional regex or string to match file content.
Optionalmessage: stringOptional custom assertion message.
ProtectedassertAssert that output contains valid JSON and optionally validate it.
The command result to parse.
Optionalvalidator: (json: T) => booleanOptional function to validate the parsed JSON.
Optionalmessage: stringOptional custom assertion message.
ProtectedassertAssert that a file does not exist.
The file path to check.
Optionalmessage: stringOptional custom assertion message.
ProtectedassertAssert that output contains a pattern.
The command result to check.
Regex or string pattern to match against output.
Optionalmessage: stringOptional custom assertion message.
ProtectedassertAssert that a command succeeded (exit code 0).
The command result to check.
Optionalmessage: stringOptional custom assertion message.
ProtectedrunRun a CLI command and return the result.
The CLI command to run.
Optionaloptions: { cwd?: string; env?: { [key: string]: string } }Optional overrides.
Optionalcwd?: stringWorking directory for the command.
Optionalenv?: { [key: string]: string }Environment variables for the command.
ProtectedrunRun a command without capturing output (for interactive commands). Returns only success/failure.
The CLI command to run.
Optionaloptions: { cwd?: string; env?: { [key: string]: string } }Optional overrides.
Optionalcwd?: stringWorking directory for the command.
Optionalenv?: { [key: string]: string }Environment variables for the command.
Run the entire test suite.
The doctor context for this suite run.
The list of test results.
ProtectedtestRegister a test with a name and function.
The test name.
The async test function.
ProtectedtestsOverride this method to register tests using this.test().
Base class for doctor test suites.
Write tests using the test() method.