-
Notifications
You must be signed in to change notification settings - Fork 74
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
[bug] Cannot find playwright package #338
Comments
Bump on this one. I’m seeing the same issue with the latest playwright / storybook. Specifically here is what I’m seeing Install just @playwright/test and you get this error when trying to run test-storybook but playwright itself works fine. |
I was also able to run test-storybook after manually installing |
@pepjo the issue is that you will not be able to use playwright now. I apparently missed this before in the playwright release notes for version 1.34.0 npx playwright test no longer works if you install both playwright and @playwright/test. There's no need // automation.ts So the issue is that test-runner uses jest-playwright-present which requires the playwright-chromium package but playwright won't let you do that anymore. Interestingly jest-playwright-preset is deprecated so I'm going to see if there is a way not to use it by hacking something up. |
So circling back to this we found an interesting thing. For some reason we had a playwright folder in our mono repo and for some reason it was trying to import from that folder and failing. Once we renamed that worked we could just install @playwright/test and everything worked with both storybook and playwright. |
We are encountering this same issue. I installed Turns out the workaround is to install |
I've also encountered this issue - the documentation could do with an update to reflect the required changes. |
Commenting as of today, installing version 8.3.5 |
Hey everyone, can anyone share a reproduction to this issue? And also to confirm whether this only happens with Yarn Berry with PnP mode? |
As of now the only workaround for us is to add the direct playwright dependency into the root package,json of monorepo, this lets storybook playwright tests to complete, but the playwright tests in the other components are not run, since they are using the @playwright/test dependency, as it is recommended by the Playwright team in the latest versions. So its either or problem. Steps to reproduce:
This issue could be potentially fixed by completing the #510 ticket. |
Describe the bug
While using Yarn 3 and after following these installation steps, running test-storybook shows the following error:
What problem could cause this, and is there a workaround?
To Reproduce
Steps to reproduce the behavior:
Expected behavior
Expectation is that the test-runner correctly locates playwright.
Screenshots
If applicable, add screenshots to help explain your problem.
System
MacOS
Node 18
Yarn 3
Storybook 7.1.0
The text was updated successfully, but these errors were encountered: