Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

allow args.background parameter for go.test.* commands #3155

Open
wants to merge 5 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions extension/src/goTest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -225,6 +225,7 @@ async function runTestAtCursor(
functions: testConfigFns,
isBenchmark: cmd === 'benchmark',
isMod,
background: !!args?.background,
applyCodeCoverage: goConfig.get<boolean>('coverOnSingleTest')
};
// Remember this config as the last executed test.
Expand Down Expand Up @@ -326,6 +327,7 @@ export function testCurrentPackage(isBenchmark: boolean): CommandFactory {
flags: getTestFlags(goConfig, args),
isBenchmark,
isMod,
background: !!args?.background,
applyCodeCoverage: goConfig.get<boolean>('coverOnTestPackage')
};
// Remember this config as the last executed test.
Expand Down Expand Up @@ -356,6 +358,7 @@ export const testWorkspace: CommandFactory = () => (args: any) => {
const testConfig: TestConfig = {
goConfig,
dir: workspaceUri.fsPath,
background: !!args?.background,
flags: getTestFlags(goConfig, args),
includeSubDirectories: true
};
Expand Down Expand Up @@ -403,6 +406,7 @@ export function testCurrentFile(isBenchmark: boolean, getConfig = getGoConfig):
functions: testFunctions?.map((sym) => sym.name),
isBenchmark,
isMod,
background: !!args?.background,
applyCodeCoverage: goConfig.get<boolean>('coverOnSingleTestFile')
};
// Remember this config as the last executed test.
Expand Down