Open karyon opened 8 months ago
Investigation: The devtools: true
option does not get taken into account when using the VSCode extension.
When running the tests via the CLI, it works: npx playwright test --project=chromium --headed api-mocking:5
.
Ah I forgot! When using chromium.launch
in test code, it works too.
I agree with @odinho in #30025, the VSCode debugging doesn't seem like an adequate replacement for the chrome devtools at the moment. I used this to debug code in page.evaluate, whereas putting breakpoints in VSCode in a page.evaluate doesn't seem to do anything. I'll have to continue using args: ['--auto-open-devtools-for-tabs']
which seems like a poor workaround.
Version
1.42.1
Steps to reproduce
Expected behavior
Browser opens and has devtools open
Actual behavior
Browser opens but does not have devtools open
Additional context
browserType.launch() docs launchOptions docs say any browserType.launch() option (docs) can be used In https://github.com/microsoft/playwright/issues/28529#issuecomment-1845009195 someone is reporting this is working for them In playwright.config.ts, uncomment
args: ['--auto-open-devtools-for-tabs']
, this does work.Environment