diff --git a/package.json b/package.json index bf9acc85ea..b419f325f9 100644 --- a/package.json +++ b/package.json @@ -775,11 +775,22 @@ "type": "string", "enum": [ "FromPreference", + "Minimal", "Normal", - "Minimal" + "Diagnostic" ], "default": "FromPreference", "description": "Defines the verbosity of output to be used. For Pester 5 and newer the default value FromPreference, will use the Output settings from the $PesterPreference defined in the caller context, and will default to Normal if there is none. For Pester 4 the FromPreference and Normal options map to All, and Minimal option maps to Fails." + }, + "powershell.pester.debugOutputVerbosity": { + "type": "string", + "enum": [ + "Minimal", + "Normal", + "Diagnostic" + ], + "default": "Diagnostic", + "description": "Defines the verbosity of output to be used when debugging a test or a block. For Pester 5 and newer the default value Diagnostic will print additional information about discovery, skipped and filtered tests, mocking and more." } } }, diff --git a/src/features/PesterTests.ts b/src/features/PesterTests.ts index de53100992..24ddf5759f 100644 --- a/src/features/PesterTests.ts +++ b/src/features/PesterTests.ts @@ -113,7 +113,12 @@ export class PesterTestsFeature implements IFeature { launchConfig.args.push("-MinimumVersion5"); } - launchConfig.args.push("-Output", `'${settings.pester.outputVerbosity}'`); + if (launchType === LaunchType.Debug) { + launchConfig.args.push("-Output", `'${settings.pester.debugOutputVerbosity}'`); + } + else { + launchConfig.args.push("-Output", `'${settings.pester.outputVerbosity}'`); + } return launchConfig; } diff --git a/src/settings.ts b/src/settings.ts index fdaacab742..68cc6bd265 100644 --- a/src/settings.ts +++ b/src/settings.ts @@ -119,6 +119,7 @@ export interface ISideBarSettings { export interface IPesterSettings { useLegacyCodeLens?: boolean; outputVerbosity?: string; + debugOutputVerbosity?: string; } export function load(): ISettings { @@ -189,6 +190,7 @@ export function load(): ISettings { const defaultPesterSettings: IPesterSettings = { useLegacyCodeLens: true, outputVerbosity: "FromPreference", + debugOutputVerbosity: "Diagnostic", }; return {