Skip to content

[BUG] Update Snapshot is displayed in test item menu #1207

@oxdev03

Description

@oxdev03

Describe the bug
A clear and concise description of what the bug is.

To Reproduce
Steps to reproduce the behavior:

  1. Open a project using vitest
  2. right click on test item
  3. "Update Snapshot button is displayed from jest"

Expected behavior
The Update Snapshot Button is only displayed for jest tests. It can be quite disturbing, if the button is accidently pressed, which activates the jest extension for the project.

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

Environment (please complete the following information):

  • vscode-jest version:latest , default settings

Additional context
Will adding "when": "controllerId == 'jest'" to testing/item/gutter and testing/item/context fix the issue or is there a background why its not used yet?

I can open a PR, if the suggested fix is sufficient to resolve the issue.


Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions