vitest-dev / vitest-dev/vscode

typecheck settings is not respected

Open
#367 6 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

p3-minor-bug
Dominant language
TypeScript
Stars
924
Forks
122
Avg merge
1d 14h
Merged PRs (30d)
6

Description

Describe the bug

typecheck settings is not respected

tmp

in the gif you can see:

  • running npx vitest correctly check typing.
  • running the test from the IDE extension does not catch type error, even though this file only checks for typing only
  • this extension should respect filed *.test-d.ts for type tests only tests.
Reproduction

first of all, awesome extension!

to reproduce:

git clone https://github.com/Eliav2/express-typed
// or, checkout exact commit (in case the repo would be changed)
git clone --bare https://github.com/Eliav2/express-typed.git
cd express-typed.git
git checkout 6aec67bfe1c849edfac0a85d41a1df0faa60cb0d

now run npx vitest at root directory, or run tests from the IDE.

OR small example

from vitest docs - Play Online

This extension would not correctly catch type.test-d.ts type errors.

Output
.
Version

v0.8.6

Validations

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the issue in the linked express-typed commit and in the Vitest typecheck example, comparing npx vitest with running tests from the IDE extension. Inspect the extension's test execution and typecheck handling, especially how *.test-d.ts files are treated. Done means type errors in type-only test files are reported when tests run from the extension.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript, vscode
Domain
devtools, testing-qa
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.