Commit Graph

1721 Commits

Author SHA1 Message Date
Ross Wollman
8d639ae50e
chore: revert toHaveAttribute type sig and overloads (#17406)
Relates #16517.

Revert "docs(python): add missing NotToHaveAttribute overloads (#17371)"

This reverts commit 2e1ea29614.

Revert "docs(release-notes): add 1.26 release notes for language ports
(#17345)"

This reverts commit 4b8a85e69d.

Revert "test: unflake "should support boolean attribute with options"
(#17024)"

This reverts commit 1dc05bd4c6.

Revert "fix: support toHaveAttribute(name, options) (#16941)"

This reverts commit f30ac1d678.

Revert "feat: expect(locator).toHaveAttribute to assert attribute
presence (#16767)"

This reverts commit 622c73cc1e.
2022-09-16 11:17:35 -07:00
Pavel Feldman
e92bdce383
chore: remove connect options after testing (#17380) 2022-09-15 20:37:21 -07:00
Dmitry Gozman
43304e980d
feat: show browser.close() stack in "Browser has been closed" error (#17376)
Often times we see "Browser has been closed" error, but it's not
entirely clear why. Showing the close stack might help.

```js
page.goto: Connection closed
    ==== Closed by ====
    at /Users/dgozman/code/playwright/tests/library/browsertype-connect.spec.ts:477:32
```
2022-09-15 17:04:41 -07:00
Andrey Lushnikov
b09ea69024
chore(docker): address docker offline comments (#17377)
This patch:
- Removes all `process.exit(1)` from `docker.ts` and instead throws
  errors.
- Drops the `npx playwright docker test` command. We agreed to
  engage docker when `PLAYWRIGHT_DOCKER` environment variable
  is set.
- Introduces hidden `npx playwright docker status` command that
  dumps a JSON with docker status:
  ```sh
  aslushnikov:~/prog/playwright$ npx playwright docker status
  {
    "dockerEngineRunning": true,
    "imageName": "playwright:local-1.27.0-next-focal",
    "imageIsPulled": true,
"containerWSEndpoing":
"ws://127.0.0.1:55077/eafeb84c-571b-4d12-ac51-f6a2b43e9155",
"containerVNCEndpoint":
"http://127.0.0.1:55076/?path=fb6d4add-9adf-4c3c-b335-893bdc235cd7&resize=scale&autoconnect=1"
  }
  ```
2022-09-15 15:48:12 -07:00
Pavel Feldman
30ff27843a
chore: rebuild components on new vite (#17367) 2022-09-15 15:24:01 -07:00
Pavel Feldman
016883602d
chore: roll test runner to tot (#17351) 2022-09-14 19:51:22 -07:00
Andrey Lushnikov
8466c436c9
fix(list reporter): properly count new lines for long stdout (#17339) 2022-09-14 15:25:24 -07:00
Andrey Lushnikov
a12112c24d
devops(docker): add docker integration smoke tests (#17267) 2022-09-14 15:05:18 -07:00
Max Schmitt
59c32bf2c6
Revert "chore(generator): use new .NET test attributes (#17172)" (#17344)
This reverts commit 15add13a6a.
2022-09-14 22:44:38 +02:00
Andrey Lushnikov
4f11a4d5e7
feat(docker): use the __screenshots__ dir for snapshots by default (#17311)
This patch opts into the `__screnshots__` folder snapshot management
for docker.

With this patch, docker-originating snapshots will be stored in the
following folder:

```
{testDir}/__screenshots__/{projectName}/{testFilePath}/{snapshotName}
```

Where `{testFilePath}` is a test file path relative to `testDir`

Drive-by: introduce and document the `PLAYWRIGHT_DOCKER` environment
variable that enables docker integration.
2022-09-13 15:49:04 -07:00
Dmitry Gozman
68072a5d5c
test: improve debugability of installation tests (#17277)
Put more details into the error message. This way it is immediately seen
on the bots.
2022-09-13 14:43:11 -07:00
Max Schmitt
00a3b1b0a2
fix: make evaluate work with overridden Window/Document/Node (#17288)
Fixes https://github.com/microsoft/playwright/issues/17287
2022-09-13 18:21:07 +02:00
Dmitry Gozman
48ac918cec
test: unflake "should load web server w/o esm loader in ems module" (#17269) 2022-09-12 11:42:04 -07:00
sand4rt
344077b04e
feat(ct): svelte mount type (#17228) 2022-09-12 09:30:04 -07:00
sand4rt
72a18754ef
core(ct): rename tests (#17216) 2022-09-12 09:27:53 -07:00
Andrey Lushnikov
af042beb13
feat: introduce docker integration (#16382)
This patch introduces the following commands:
- `npx playwright docker build` that builds a VRT docker image
  locally that is based off the `mcr.microsoft.com/playwright:jammy`
- `npx playwright docker start` that launches a docker container with
  browsers.
- `npx playwright docker stop` that stops given docker container.
- `npx playwright docker test` that runs all the tests inside a
  launched docker container.
2022-09-09 15:25:42 -07:00
Yury Semikhatsky
24ee456d43
chore: make maxRedirects available in java, improve docs. tests (#17227) 2022-09-09 13:25:36 -07:00
Vincenzo Gasparo
17b203affb
feat: added follow and redirect arguments to fetch (#17033) 2022-09-09 12:14:42 -07:00
Dmitry Gozman
bca13bc35a
feat(assertions): support toBeVisible({ visible }) (#17207) 2022-09-09 08:33:23 -07:00
Dmitry Gozman
cbc8d1a19f
test: tracing works with waitForResponse (#17176) 2022-09-08 11:31:02 -07:00
Andrey Lushnikov
ea7ef328e7
fix: inject caret-hiding style in every shadow tree (#16907)
Style inheritance disregards selector specificity, so we can't
dominate local shadow dom styles.

To mitigate this, we inject the style tag with caret-hiding
style in every shadowDom tree.

Fixes #16732
2022-09-08 09:50:08 -07:00
sand4rt
098fbf0e2c
fix(ct): vue import errors (#17066) 2022-09-08 08:37:38 -07:00
Max Schmitt
1e517731ef
chore: have a socket timeout when downloading browsers (#17187) 2022-09-08 14:40:41 +02:00
Max Schmitt
22c092db10
test: fix Electron tests (#17180) 2022-09-08 09:11:47 +02:00
Pavel Feldman
80e9c5dc55
fix(reuse): restore storage state (#17175) 2022-09-07 19:15:04 -07:00
Max Schmitt
15add13a6a
chore(generator): use new .NET test attributes (#17172) 2022-09-08 01:44:58 +02:00
Pavel Feldman
c91df61ca3
chore: optionally connect instead of launching (#17174) 2022-09-07 15:57:20 -07:00
Max Schmitt
14ec71b905
chore: roll stable test-runner to 1.26.0-alpha-sep-7-2022 (#17166) 2022-09-07 20:11:09 +02:00
Max Schmitt
904801a5eb
test: add initial webview2 tests (#16827) 2022-09-07 20:09:22 +02:00
Dmitry Gozman
6e1c94b5fe
fix(click): allow clicking inside closed shadow root (#16900)
Although Playwright selectors do not pierce closed shadow roots,
one can still obtain a reference to an element inside a closed shadow root:
- through `page.evaluate()`;
- through `handle.$()` where `handle` is inside the shadow root;
- through `frame.locator()` by choosing an iframe that belongs
  to a closed shadow root.

In this case, `click()` action fails during the hit check test,
but it's possible to make it work by going bottom up from the target
rather than top down from the document.
2022-09-06 17:55:15 -07:00
Yury Semikhatsky
fbf9ca5316
fix: avoid using builtins in injected script bundles (#17145) 2022-09-06 17:25:02 -07:00
Pavel Feldman
8d25f2ef59
fix(selectors): allow custom engines in out-of-process (#17139) 2022-09-06 14:15:53 -07:00
Dmitry Gozman
f0c5810609
feat(assertions): support toBeEditable({ editable }) (#17065) 2022-09-06 12:50:45 -07:00
Dmitry Gozman
306ab34aa3
feat(assertions): support toBeEnabled({ enabled }) (#17058) 2022-09-06 11:40:34 -07:00
Dmitry Gozman
b734f36f8b
fix(frameElement): should work for frames inside closed shadow root (#17055) 2022-09-06 08:52:25 -07:00
Pavel Feldman
f4b90e5cc8
chore: reparent network back to context (#17023) 2022-09-05 10:19:44 +02:00
Yury Semikhatsky
01d83f1d5e
fix(har): record request overrides to har (#17027) 2022-09-04 10:52:20 -07:00
Dmitry Gozman
54e7f44974
fix(firefox): disable cookie partitioning (#17051) 2022-09-02 15:46:03 -07:00
Dmitry Gozman
1b59abb5e1
chore: fix lint in page-goto.spec (#17052) 2022-09-02 15:45:01 -07:00
Yury Semikhatsky
10b22aca88
test: third party cookies via an iframe on wk mac (#17050) 2022-09-02 15:03:39 -07:00
Max Schmitt
8f1f4946bf
test: send cookies via an embedded iframe (#17036) 2022-09-02 11:00:55 -07:00
Dmitry Gozman
3548f3f898
feat(firefox): roll ff to 1350, beta to 1353 (#17006) 2022-09-02 08:35:29 -07:00
Yury Semikhatsky
da19219323
fix: throw clear message when requested screenshot is too large (#17025) 2022-09-01 18:15:49 -07:00
Dmitry Gozman
1dc05bd4c6
test: unflake "should support boolean attribute with options" (#17024)
Timeout 100ms is too small.
2022-09-01 17:04:54 -07:00
Yury Semikhatsky
27ffdcc944
fix: accept post data for GET and HEAD http methods (#17008) 2022-09-01 08:36:08 -07:00
Andrey Lushnikov
fafd9837ba
feat: introduce the --ignore-snapshots option (#17004)
This patch introduces `--ignore-snapshots` Playwright Test CLI option,
and `ignoreSnapshots` configuration argument.
2022-09-01 05:34:36 -07:00
Yury Semikhatsky
5d6253f743
fix: stop har recording when APIRequestContext is disposed (#17007) 2022-08-31 21:51:38 -07:00
Yury Semikhatsky
aaa28394cd
feat(trace): include url into route.fulfill call params (#16934) 2022-08-31 12:37:49 -07:00
nate-ro
409bab59ea
chore: added starting time of test to the base json reporter (#16885) 2022-08-30 20:03:21 -07:00
Yury Semikhatsky
f30ac1d678
fix: support toHaveAttribute(name, options) (#16941) 2022-08-30 17:53:00 -07:00