Update playwright-setup.md
This commit is contained in:
parent
b6d19d1c6a
commit
99cc3a8167
1 changed files with 17 additions and 11 deletions
|
|
@ -1,16 +1,5 @@
|
||||||
pretty standard setup that you get from `npm init playwright@latest`
|
pretty standard setup that you get from `npm init playwright@latest`
|
||||||
|
|
||||||
```json
|
|
||||||
{
|
|
||||||
"scripts": {
|
|
||||||
"playwright": "DEBUG=pw:webserver npx playwright test flow/open-account-regular ",
|
|
||||||
}
|
|
||||||
}
|
|
||||||
```
|
|
||||||
added the DEBUG env var to see logging of the wds server startup while running playwright
|
|
||||||
|
|
||||||
the WDS setup is in [here](web-dev-server.md)
|
|
||||||
|
|
||||||
```typescript
|
```typescript
|
||||||
import { defineConfig, devices } from '@playwright/test';
|
import { defineConfig, devices } from '@playwright/test';
|
||||||
|
|
||||||
|
|
@ -56,3 +45,20 @@ export default defineConfig({
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
```
|
```
|
||||||
|
|
||||||
|
`package.json`
|
||||||
|
```json
|
||||||
|
{
|
||||||
|
"scripts": {
|
||||||
|
"playwright": "DEBUG=pw:webserver npx playwright test flow/open-account-regular ",
|
||||||
|
"playwright:headed": "DEBUG=pw:webserver npx playwright test flow/open-account-regular --headed",
|
||||||
|
"playwright:ui": "npx playwright test flow/open-account-regular --ui",
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
|
added the DEBUG env var to see logging of the wds server startup while running playwright
|
||||||
|
|
||||||
|
for convinience and to inform your mates I added the 2 options with `--headed` and `--ui`. Use the ui to develop your tests
|
||||||
|
|
||||||
|
the WDS setup is in [here](web-dev-server.md)
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue