Skip to content

Fix/update to api #43

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

Merged
merged 12 commits into from
Oct 15, 2019
Next Next commit
update schema
  • Loading branch information
ShMcK committed Oct 14, 2019
commit db1af326bda65c6360e2453e57f988af5ccebeca
14 changes: 2 additions & 12 deletions src/actions/runTest.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
import * as vscode from 'vscode'
import node from '../services/node'

// TODO: use tap parser to make it easier to support other test runners

// ensure only latest run_test action is taken
let currentId = 0

Expand Down Expand Up @@ -35,12 +37,6 @@ async function runTest({onSuccess, onFail, onRun, onError}: Props): Promise<void

const outputChannelName = 'Test Output'

// TODO: validate test directory from package.json exists
// let testFile = path.join('test');
// if (!await exists(testFile)) {
// return emptyTasks;
// }

// TODO: verify test runner for args
// jest CLI docs https://jestjs.io/docs/en/cli
const testArgs = [
Expand All @@ -51,12 +47,6 @@ async function runTest({onSuccess, onFail, onRun, onError}: Props): Promise<void
'--maxWorkers=4'
]

// if .git repo, use --onlyChanged
// const hasGit = path.join('.git');
// if (await exists(hasGit)) {
// testArgs.push('--onlyChanged')
// }

const commandLine = `npm test -- ${testArgs.join(' ')}`

try {
Expand Down
Loading