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

[Test Runner] Run works fine but debug reports incorrect test result with "Failed to get any result" #177

Closed
JustinGrote opened this issue Sep 1, 2023 · 1 comment

Comments

@JustinGrote
Copy link

JustinGrote commented Sep 1, 2023

Type: Bug

Describe the bug
When using the debug button, the api options do not seem to get added to the command and therefore no results are reported

[INFO 4:55:16 PM] [Execute Vitest] pnpm test -- C:/Users/jgrote/Projects/PWSHGallery/src/registration.spec.ts -t UnstableDevWorker E2E ServiceIndex returns OK
[INFO 4:55:16 PM] Start api process at port 56345
[INFO 4:55:16 PM] [RUN] pnpm test -- C:/Users/jgrote/Projects/PWSHGallery/src/registration.spec.ts -t UnstableDevWorker E2E ServiceIndex returns OK
[INFO 4:55:16 PM] [RUN.cwd] C:/Users/jgrote/Projects/PWSHGallery
[INFO 4:55:17 PM] WS Close
[INFO 4:55:17 PM] RECONNECT
[INFO 4:55:17 PM] WS Close
[INFO 4:55:17 PM] Debugging started
[INFO 4:55:18 PM] RECONNECT
[INFO 4:55:18 PM] WS Close
[INFO 4:55:18 PM] RECONNECT
[INFO 4:55:18 PM] WS Close
[INFO 4:55:18 PM] API PROCESS EXIT
[INFO 4:55:18 PM] Vitest api process finished
[Error 4:55:18 PM] 
Failed to get any result
( Vitest should be configured to be able to run from project root )

Error when running
    pnpm test -- C:/Users/jgrote/Projects/PWSHGallery/src/registration.spec.ts -t UnstableDevWorker E2E ServiceIndex returns OK

cwd: C:/Users/jgrote/Projects/PWSHGallery
node: v16.17.1

env.PATH: undefined

[Error 4:55:18 PM] Debugging started
[INFO 4:55:19 PM] RECONNECT
[INFO 4:55:19 PM] WS Close

To Reproduce

  1. Start run and note the api parameters are added in the Output window
  2. Start debug and note they are not present. Note that test results do not reflect latest change (e.g. try changing a success test to failed test)

Expected behavior
Debug to report a proper test result

Screenshots
If applicable, add screenshots to help explain your problem.

Environment

(Paste info.txt content generated by the example project)

  • OS: Windows 11 Insider
  • VSCode version: 1.81.1
  • Vitest version: 0.34.3 (vitest-environment-miniflare 2.14.1)
  • Vitest plugin version: v0.2.42

Additional context
Add any other context about the problem here.

Extension version: 0.2.42
VS Code version: Code 1.81.1 (6c3e3dba23e8fadc360aed75ce363ba185c49794, 2023-08-09T22:22:42.175Z)
OS version: Windows_NT x64 10.0.23451
Modes:

System Info
Item Value
CPUs AMD Ryzen 7 6800U with Radeon Graphics (16 x 2695)
GPU Status 2d_canvas: enabled
canvas_oop_rasterization: disabled_off
direct_rendering_display_compositor: disabled_off_ok
gpu_compositing: enabled
multiple_raster_threads: enabled_on
opengl: enabled_on
rasterization: enabled
raw_draw: disabled_off_ok
video_decode: enabled
video_encode: enabled
vulkan: disabled_off
webgl: enabled
webgl2: enabled
webgpu: enabled
Load (avg) undefined
Memory (System) 15.19GB (1.19GB free)
Process Argv --file-uri file:///c%3A/Users/jgrote/Projects/vscode-powershell/extension-dev.code-workspace --crash-reporter-id a45c1268-117e-410a-a083-cc3d7e68707f
Screen Reader no
VM 0%
A/B Experiments
vsliv368:30146709
vsreu685:30147344
python383cf:30185419
vspor879:30202332
vspor708:30202333
vspor363:30204092
vswsl492cf:30256860
vslsvsres303:30308271
vserr242cf:30382550
pythontb:30283811
vsjup518:30340749
pythonptprofiler:30281270
vshan820:30294714
vstes263cf:30335440
vscoreces:30445986
vscod805cf:30301675
binariesv615:30325510
bridge0708:30335490
bridge0723:30353136
vsaa593:30376534
pythonvs932:30410667
vsclangdf:30486550
c4g48928:30535728
dsvsc012cf:30540253
pynewext54:30695312
azure-dev_surveyone:30548225
vscccc:30803845
282f8724:30602487
89544117:30613380
showlangstatbar:30737416
03d35959:30757346
pythonfmttext:30731395
fixshowwlkth:30771522
showindicator:30805244
pythongtdpath:30769146
i26e3531:30792625
pythonnosmt12:30797651
pythonidxpt:30805730
pythonnoceb:30805159
dsvsc013:30795093
dsvsc014:30804076
diffeditorv2:30821572
dsvsc015cf:30823818

@sheremet-va
Copy link
Member

This should be fixed in pre-release 0.5.0 and higher. Note that the extension now requires Vitest 1.4.0 or higher.

@github-actions github-actions bot locked and limited conversation to collaborators Mar 30, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants