892 Commits

Author SHA1 Message Date
Max Schmitt
010778f6c5
feat(client-certificates): allow passing certificates from memory (#32210) 2024-08-19 09:24:32 +02:00
Kuba Janik
0588834307
feat: allow URLSearchParams and string as params in APIRequestContext (follow-up) (#32143)
Follow-up to https://github.com/microsoft/playwright/pull/32120

I made some changes suggested by @yury-s in the previous PR that make a
lot of sense:
- added an example to the documentation
- improved tests
  - check params on the client and server end
  - reverted to non-English characters being used as params
2024-08-13 10:39:56 -07:00
Max Schmitt
b7ed4d7b9e
docs: deprecate: Request.serviceWorker() (#32136) 2024-08-13 15:59:30 +02:00
Kuba Janik
308381eeae
feat: allow URLSearchParams and string as params in APIRequestContext (#32120) 2024-08-12 14:22:03 -07:00
Yury Semikhatsky
2ae196f708
fix(docs): API types do not extend EventEmitter (#32124)
Fixes https://github.com/microsoft/playwright/issues/32097
2024-08-12 11:22:48 -07:00
Yury Semikhatsky
43e852334b
docs: route.fallback() vs. route.continue() (#32035)
Fixes https://github.com/microsoft/playwright/issues/31983
2024-08-06 11:35:53 -07:00
Pavel Feldman
3c87f217df
feat(events): allow waiting for removeAllListeners (#31941) 2024-08-05 21:14:35 -07:00
Yury Semikhatsky
193013c9ee
docs(har): default update mode is minimal (#32016)
Update the documentation to match actual behavior.

The actual behavior today:
* Default mode is `full` when `recordHar` is passed to
`browser.newContext`
* Default mode is `minimal` when calling `context.routeFromHAR` and
`page.routeFromHAR`

Reference https://github.com/microsoft/playwright/issues/31983
2024-08-05 11:29:43 -07:00
Max Schmitt
55187207e4
chore: various roll fixes for .NET (#31914) 2024-07-30 19:09:20 +02:00
Max Schmitt
f45cf65921
chore: add maxRetries to APIRequestContext.delete (#31893) 2024-07-29 14:39:30 +02:00
Max Schmitt
7570c25b3d
chore: remove glob from client-certificate matching (#31846)
Signed-off-by: Max Schmitt <max@schmitt.mx>
Co-authored-by: Dmitry Gozman <dgozman@gmail.com>
2024-07-24 19:13:03 +02:00
Max Schmitt
c4862c022c
chore: client certificates api review (#31826) 2024-07-23 22:56:36 +02:00
Yury Semikhatsky
383e4b3c73
Revert "feat: introduce touchscreen.touch() for dispatching raw touch… (#31823)
… events (#31457)"

This reverts commit a3e31fd2c4146e67a63ff4d3dc4f655533adcbde.
2024-07-23 10:29:37 -07:00
Simon Knott
2cc4e14756
fix(core): update maxRetries docs (#31810) 2024-07-23 08:27:27 -07:00
Yury Semikhatsky
e269092ef9
Revert "fix: add 'window-management' to chromium browser (#31687)" (#31801)
This reverts commit 0aa2f06f68959e2515f62ea9bb570cf1815230b2.

Discussed the new permission in the API review and decided not to
proceed with the feature as we are not ready to commit to supporting it
yet:
* the API is Chromium specific
* the API is still experimental
* there is no clarity to what extend the screen manipulation APIs will
work in old headless which is our main test environment

We'll keep an eye on the demand for the feature and may get back to
implementing it in the future.

Reference: https://github.com/microsoft/playwright/issues/27198
2024-07-22 11:27:12 -07:00
Josh Soref
7abbbd0c84
docs: spelling (#31779)
Fixes misspellings identified by the [check-spelling
action](https://github.com/marketplace/actions/check-spelling).

The misspellings have been reported at
https://github.com/jsoref/playwright/actions/runs/10015023629#summary-27685777352

The action will report that the changes in this PR would make it happy:
https://github.com/jsoref/playwright/actions/runs/10015023971#summary-27685778305

---

I understand that the commit messages will need to be reworded to match
house style. For the time being, these are merely noting the changes
they contain so that when I rebase or need to drop things, I can. --
I've already rebased once as someone fixed one of the items that my
draft work was going to fix.

---

## Testing
* The tests _mostly_ passed when I managed to trigger them, but there
were a handful of things that I didn't quite understand
* There are a large number of warnings relating to a bad interaction
between any workflow that uses this local action
b535139b32/.github/actions/run-test/action.yml (L74-L80)
and the action it calls -- I've opened Azure/login#474 asking them to
refactor their action so that it doesn't cause so much noise while
running this repository's tests
* I'm vaguely curious as to why this repository has a `branch`
constraint for its `pull_request` events in its workflows -- that
constraint gave me a number of additional headaches while trying to
prepare this branch for this PR.

---------

Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2024-07-22 06:45:22 -07:00
Dmitry Gozman
6491e5b415
chore: deprecate/remove noWaitAfter from some actions (#31739)
The following actions keep `noWaitAfter` option: `click`, `selectOption`
and `press`.

All other actions that used to have `noWaitAfter` now behave like it was
set to true, not waiting for follow-up navigations. In the docs, this
option is marked as completely ignored.

A small logic change was made to compensate for this behavior: when
waiting for the `hitTargetInterceptor`, we now race it against
navigations to avoid stalling when navigation stalls. Previously,
waiting for the interceptor was disabled when `noWaitAfter` was passed,
and since it's impossible to pass this option now, we mitigate by never
stalling instead.

Fixes #31469.
2024-07-18 00:19:08 -07:00
Ismael Onilearan
0aa2f06f68
fix: add 'window-management' to chromium browser (#31687) 2024-07-15 14:34:57 -07:00
Max Schmitt
9569cb5c1e
feat: support client certificates (#31529)
Signed-off-by: Max Schmitt <max@schmitt.mx>
Co-authored-by: Dmitry Gozman <dgozman@gmail.com>
2024-07-12 11:42:24 +02:00
Max Schmitt
5c8fe5c33c
docs: make x/y more clear (#31606)
Fixes https://github.com/microsoft/playwright/issues/31567
2024-07-09 12:52:51 +02:00
Max Schmitt
2b974f2139
docs(clock): update time types in Python/.NET (#31511) 2024-07-03 10:46:33 +02:00
Yury Semikhatsky
a3e31fd2c4
feat: introduce touchscreen.touch() for dispatching raw touch events (#31457) 2024-06-27 14:37:36 -07:00
Yury Semikhatsky
111876d526
docs: improve addCookies.cookie parameter description (#31456) 2024-06-26 15:39:43 -07:00
Dmitry Gozman
114b6f0de6
docs: deprecate handle option in exposeBinding (#31419) 2024-06-24 11:29:40 -07:00
Yury Semikhatsky
865f0d8221
docs(java): correctly parse time (#31420) 2024-06-24 11:28:43 -07:00
Yury Semikhatsky
95fc2b8a8b
feat(fetch): maxRetries for fetch (#31386)
Fixes https://github.com/microsoft/playwright/issues/30978
2024-06-19 18:10:14 -07:00
Yury Semikhatsky
f6972c1e23
docs: use long for time in milliseconds (#31369)
In Java and .NET int is not enough to store millis since epoch.
2024-06-18 10:47:29 -07:00
Max Schmitt
a76e5824c0
docs: examples for file directory upload (#31302) 2024-06-13 23:37:47 +02:00
Max Schmitt
dcf4e4e054
feat: allow folder uploads (#31165) 2024-06-12 22:20:18 +02:00
Pavel Feldman
2b257ea963
chore(clock): introduce pauseAt (#31255) 2024-06-11 12:51:00 -07:00
Pavel Feldman
6399e8de4e
chore: clock api review (#31237) 2024-06-11 09:42:15 -07:00
Yury Semikhatsky
c08000b967
feat(chromium): storage-access permission (#31239)
Fixes https://github.com/microsoft/playwright/issues/31227
2024-06-11 09:18:45 -07:00
Max Schmitt
f95b4e0ac8
docs(dotnet): recommend MSTest over NUnit (#31245) 2024-06-11 15:06:03 +02:00
Pavel Feldman
826343b8a0
chore: rename fakeTimers to clock (#31193) 2024-06-06 15:56:13 -07:00
Darío Kondratiuk
76b25e84cc
docs: Improve clock doc (#31147) 2024-06-04 18:48:56 +02:00
Pavel Feldman
c516ba0ec8
api(clock): rework api based on the review (#31137) 2024-06-04 06:51:35 -07:00
Pavel
8d0def190d docs: iterate over the clock (2) 2024-06-03 09:03:43 -07:00
Pavel
8d2f4c1433 docs: iterate over the clock dock 2024-06-01 08:22:36 -07:00
Pavel Feldman
fc6c67f5f9
docs: start adding clock docs (#31111) 2024-06-01 07:30:58 -07:00
Pavel Feldman
8bfd0eb6e4
chore: introduce clock test mode (#31110) 2024-05-31 14:44:26 -07:00
Pavel Feldman
76e977a934
chore: add clock.next() (#31097) 2024-05-31 08:09:24 -07:00
Pavel Feldman
f97d87ea5a
docs: fix the api review typos (#31071) 2024-05-30 12:15:52 -07:00
Yury Semikhatsky
6067b78f88
chore: http credentials send immeidately/unauthorized enum (#31076)
Reference https://github.com/microsoft/playwright-internal/issues/205
Reference https://github.com/microsoft/playwright/issues/30534
2024-05-30 10:19:56 -07:00
Pavel Feldman
170c457a61
feat(timers): a stab at fake timers (#31075) 2024-05-30 09:38:27 -07:00
cavivie
a7599ad509
feat(api): add host option in launchServer options (#30999) 2024-05-27 11:24:23 +02:00
Olaf Alders
5b00ce1594
docs: fix typo in ConsoleMessage class (#30857) 2024-05-22 13:31:14 +02:00
Max Schmitt
79d2fcfc20
docs(python): fix browser.context snippet (#30759)
Signed-off-by: Max Schmitt <max@schmitt.mx>
2024-05-14 15:36:17 +01:00
Dmitry Gozman
776b04e5ea
feat: APIRequestContext dispose reason (#30765)
Similarly to page.close, we pass test-runner specific reason to
facilitate better error messages.

```
  1) a.test.ts:10:11 › test

    Error: apiRequestContext.fetch: Fixture { request } from beforeAll cannot be reused in a test.
      - Recommended fix: use a separate { request } in the test.
      - Alternatively, manually create APIRequestContext in beforeAll and dispose it in afterAll.
    See https://playwright.dev/docs/api-testing#sending-api-requests-from-ui-tests for more details.

       9 |
      10 |       test('test', async () => {
    > 11 |         await context.fetch('http://example.com');
         |                       ^
      12 |       });
      13 |
```

Closes #29260.
2024-05-13 18:51:30 -07:00
Max Schmitt
f2441eb4b5
docs(dotnet): roll fixes (#30771) 2024-05-13 15:56:14 -07:00
Yury Semikhatsky
e728e90944
docs: waitForResponse method predicate example (#30739)
Fixes https://github.com/microsoft/playwright/issues/30731
2024-05-10 09:22:59 -07:00