← Back to Discord Forum

Global setup: not able to save STORAGE_STATE

Hi, I am referring this https://playwright.dev/docs/test-global-setup-teardown#setup-example and flow seems to be quite straight and using in same way. Define projects as setup and other and used setup as depenedcies but when running the tests it's not able to find STORAG_STATE file user.json. export const STORAGE_STATE = path.join(__dirname,'playwright/.auth/user.json'); Error: Error reading storage state from

This thread is trying to answer question "Why is the user unable to save the STORAGE_STATE file user.json in the global setup?"

2 replies

It seems it's running other project first and not the setup project that's why other project is not able to find user.json

@Juhi maybe you can try if this works for you: export const STORAGE_STATE='auth/user.json'

AboutQuestionsDiscord ForumBrowser ExtensionTagsQA Jobs

Rayrun is a community for QA engineers. I am constantly looking for new ways to add value to people learning Playwright and other browser automation frameworks. If you have feedback, email luc@ray.run.