You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Feature]: Enable configuration of updateSnapshots in test scope and UI Mode #37007
Enable ad-hoc configuration of updateSnapshots in the following contexts:
In the scope of a test, e.g. via test.use()
When running tests in UI mode, via the settings
Example
test("snapshot test",async()=>{test.use({updateSnapshots: "changed"});// test using snapshots});
Motivation
updateSnapshots can currently either be enabled by passing --update-snapshots to the Playwright CLI or by configuration in the playwright.config.ts. These alternatives are harder to utilize in an ad-hoc fashion when developing tests in the IDE or running them in UI Mode. Providing options to dynamically configure updateSnapshots would provide more flexibility during development and could help to simplify updating snapshots.
Which mode selector do you mean exactly? I couldn't find one in the VS Code extension. However, I'm mostly using IntelliJ IDEA while developing. But I also have developers using VS Code in my team. When running multiple tests or analyzing errors, I prefer to use the UI Mode though, which has the advantage of being independent of the used IDE.
Activity
pavelfeldman commentedon Aug 14, 2025
There is a mode selector for that in the Playwright VS Code extension. Are you using it?
foxable commentedon Aug 15, 2025
Which mode selector do you mean exactly? I couldn't find one in the VS Code extension. However, I'm mostly using IntelliJ IDEA while developing. But I also have developers using VS Code in my team. When running multiple tests or analyzing errors, I prefer to use the UI Mode though, which has the advantage of being independent of the used IDE.
pavelfeldman commentedon Aug 15, 2025
We can add it in the UI mode