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

Playwright tests do not appear in Test Explorer of VSCode #23246

Closed
jmeijering opened this issue May 23, 2023 · 4 comments
Closed

Playwright tests do not appear in Test Explorer of VSCode #23246

jmeijering opened this issue May 23, 2023 · 4 comments

Comments

@jmeijering
Copy link

jmeijering commented May 23, 2023

System info

  • Playwright Version: [v1.34.1]
  • Operating System: [Windows ]
  • Browser: [Chromium]
  • Node version: 20.2.3

Did a fresh install of playwright VS code plug in and installed the browsers and everything worked fine: Tests were visible in the Test Explorer and could be executed by clicking on the green play button in the tests file.

Then I tried to run the tests from the terminal but it did not find any tests (probably because I used \ instead of / and at a certain moment the system suggested to install Playright via NPM, so I did and that made it possible to run the tests via the terminal but after it the tests were not displayed in the Test explorer anymore.

I have uninstalled the extension, reinstalled VSCode, reinstalled Node.js but nothing solved the issue and I'm still not able to view and execute the tests via the Test explorer anymore.

How to resolve this issue, I already found some other tickets but non of solutions which worked for other people worked form me #19863 #18954

@jmeijering jmeijering changed the title [BUG] Tests do not appear in Test Explorer May 23, 2023
@jmeijering jmeijering changed the title Tests do not appear in Test Explorer Tests do not appear in Test Explorer of VSCode May 23, 2023
@jmeijering jmeijering changed the title Tests do not appear in Test Explorer of VSCode Playwright tests do not appear in Test Explorer of VSCode May 23, 2023
@jmeijering
Copy link
Author

I found a resolution. During the reinstall of Playwrigt I had cleared all the content of the vscode folder in which I had installed playwright and then did the reinstallation, this did not solve my issue.
Now I also deleted the folder itself and created a new one and now it's all working fine again.

@guido-visser
Copy link

@jmeijering What specific folder are you talking about? The extension folder? I'm having the same issue and it's grinding my gears... Appreciate the help :)

@jmeijering
Copy link
Author

This is the directory where I put all the code C:\Users\JanMeijering\OneDrive - HSO\Documents\VsCode\Playwright2, and I only cleared the content of this directory.
But when I completely deleted the directory and created a new one with a different name and did the complete reinstallation it started to work again.

@mrkamot1979
Copy link

a bit long winded.

  1. Saw this but when I attempted to run my playwright tests, the Test Explorer was showing a blank slate.
  2. Thought of running the tests from the command line interface instead so did "npx playwright test {filename of the test}" but still causing issues.
  3. Found this solution from StackOverflow to fix the cli issue and fortunately it also fixed the issue with Visual Studio, I can now see and run the playwright tests from the Test Explorer.

in hindsight i think i did a brew update previously and perhaps this might have broken some things.

Screenshot 2023-09-22 at 9 58 56

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants