vscode icon indicating copy to clipboard operation
vscode copied to clipboard

Test Result pane is empty

Open IgorKrupenja opened this issue 2 years ago • 11 comments

Describe the bug

VSCode Test results pane is empty.

To Reproduce

Steps to reproduce the behavior on this example project. At the moment it has just a couple of very simple tests.

  1. Open the repo above from VSCode.
  2. Open Testing in Sidebar.
  3. Click run tests.

Expected behavior

Tests are run and you can see output in Test Result pane.

Instead, tests are run correctly but the pane is empty, see screenshot below. Everything else works fine.

Screenshots

image

Environment

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

  • OS: macOS 13.4.1 (c)
  • VSCode version: 1.80.1
  • Vitest version: 0.33.0
  • Vitest plugin version: v0.2.42

IgorKrupenja avatar Jul 26 '23 10:07 IgorKrupenja

Anyone else found a workaround/fix for this?

daniel-johns-99 avatar Jan 03 '24 13:01 daniel-johns-99

This happens to me too. I saw it for a split moment before it's cleared. I was hoping to click on the right-hand list of runs and see individual results.

I'll go back to my running the tests in the Terminal windows, so I can read the output.

mikechu-optimizely avatar Jan 05 '24 19:01 mikechu-optimizely

having this issue and I don't use vitest-dev but jest

bughaver avatar Jan 11 '24 01:01 bughaver

The same issue to me. image

htndev avatar Jan 15 '24 12:01 htndev

+1 same issue

Otoris avatar Jan 29 '24 21:01 Otoris

Issue Persists

oenu avatar Feb 01 '24 18:02 oenu

+1. The issue persists for quite a long period. I never saw it not clean after a test was executed. Instead, I have a new terminal with Jest results, opened in the terminals list.

olgashev avatar Feb 02 '24 16:02 olgashev

Have same issue since quite some time, is there a work around?

deeepwin avatar Feb 03 '24 18:02 deeepwin

Have same issue since quite some time, is there a work around?

Fixes it for me:

"python.testing.pytestArgs": [ "-s" ],

then click on "Show Results Output" icon on top right panel.

deeepwin avatar Feb 04 '24 09:02 deeepwin

For me setting the Output Config option to terminal-based made the output show up. Not sure why the default doesn't.

See https://github.com/jest-community/vscode-jest?tab=readme-ov-file#outputconfig

simonalbrecht avatar Feb 13 '24 07:02 simonalbrecht

I am not sure what is expected in "Test Results" panel. The same thing that Vitest outputs?

Please, don't comment here if you are using other testing frameworks. We do not control their behavior.

sheremet-va avatar Mar 15 '24 18:03 sheremet-va

Pre-release version of Vitest extension only prints user's logs in "Test Result" panel. This is by design - we decided to not replicate the same output from Vitest terminal because you can already see same results in Visual Studio Code interface, and it's actually more interactive. This also makes the extension a bit faster because we don't need to spend time to format the output.

If there is a strong reason to display the same output that Vitest does in the terminal, feel free to leave a comment. But I am closing this issue for now.

sheremet-va avatar Apr 03 '24 17:04 sheremet-va