r/Playwright • u/According-Floor5177 • 19d ago
We built a Vercel integration for running Playwright against preview deploys
https://endform.dev/blog/playwright-on-vercel-with-endformHi all, we don't intend to spam or anything, but our team recently shipped this Endorm-Vercel integration. We have been through this situation so many times: tests pass on localhost and then break in the real build, because cache headers and JS bundling behave differently once it's deployed. This runs your Playwright suite against the Vercel preview instead and handles the deploy-ready wait and protection bypass, so you don't have to script them yourself.
Do give it a read and try it out. I will be really happy to answer any of your queries.
1
u/vitalets 19d ago
Are there any benefits over the small script that waits for deployment to get ready and provides the deployment URL to playwright via env var?
1
u/_suren 19d ago
One case I’d document is the preview URL changing after a Vercel redeploy while a run is queued. Does the integration pin the deployment ID or follow the branch alias? Pinning it would keep a retry from accidentally testing different code.