Commit Graph

3200 Commits

Author SHA1 Message Date
Playwright Service
57305e985e
feat(webkit): roll to r1877 (#24330)
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2023-07-20 17:47:21 +02:00
Playwright Service
80daf47d44
feat(chromium): roll to r1073 (#24326)
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2023-07-20 16:15:56 +02:00
Playwright Service
7ba60ca91d
feat(chromium-tip-of-tree): roll to r1134 (#24325)
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2023-07-20 16:15:40 +02:00
Playwright Service
eac47ce913
feat(webkit): roll to r1876 (#24302)
Signed-off-by: Max Schmitt <max@schmitt.mx>
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Max Schmitt <max@schmitt.mx>
2023-07-19 18:24:59 +02:00
Playwright Service
20fcd6b272
feat(webkit): roll to r1875 (#24299)
Since
99ff08340f
search event is disabled in cocoa.

---------

Signed-off-by: Max Schmitt <max@schmitt.mx>
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Max Schmitt <max@schmitt.mx>
2023-07-19 18:24:21 +02:00
Max Schmitt
1288519915
fix(ui-mode): run teardown handlers with Command + C (#24267)
Fixes https://github.com/microsoft/playwright/issues/23907
2023-07-19 17:50:25 +02:00
Andrey Lushnikov
1fdd7541e0
chore: add firefox-asan for stress tests (#24049) 2023-07-19 05:53:52 -07:00
Playwright Service
fbb384483b
feat(webkit): roll to r1874 (#24297)
Signed-off-by: Max Schmitt <max@schmitt.mx>
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Max Schmitt <max@schmitt.mx>
2023-07-19 14:20:19 +02:00
Playwright Service
a136763118
feat(webkit): roll to r1873 (#24296)
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2023-07-19 14:19:05 +02:00
Max Schmitt
9af0c6d822
chore: remove glob dependency from utils bundle (#24291) 2023-07-19 05:17:34 +02:00
Pavel Feldman
879ddb73b0
chore: show last poller error on test timeout (#24292) 2023-07-18 17:03:26 -07:00
Marcin Strzyz
d5e7b4f16f
chore: update rimraf package to version 4 to eliminate "promisify" (#24190)
Migrate to version 4 which returns a promise rather than leverages a
callback. -> https://www.npmjs.com/package/rimraf?activeTab=readme

- contains its own types, eliminate "@types/rimraf"
- Parameter `maxBusyTries` changed to `maxRetries`
2023-07-18 19:58:07 +02:00
Marcin Strzyz
0eb94aaa79
chore: refactored minimum Node Major version to variable (#24188) 2023-07-18 19:57:48 +02:00
Max Schmitt
d2f581a19c
fix(test-runner): don't double emit SIGINT in long running test (#24265)
https://github.com/microsoft/playwright/issues/23907

This fixes the following scenario. You press Command + C during the
test-execution, then a global teardown will execute, which takes a long
time and before this on macOS did sometimes end up in an unwanted SIGINT
received inside the globalTeardown handler. After this change this won't
happen anymore.
2023-07-18 18:46:18 +02:00
Yury Semikhatsky
d0280ec8c7
chore(blob): drop shard number from report name (#24270)
We store shard number in the report metadata event and then sort shard
files by shard number. This guarantees that within each project sharded
events will always go in stable order.
2023-07-18 09:29:25 -07:00
Playwright Service
b24ec33aa9
feat(chromium-tip-of-tree): roll to r1133 (#24280)
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2023-07-18 15:11:01 +02:00
Playwright Service
57da4c200a
feat(chromium): roll to r1072 (#24279)
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2023-07-18 15:10:30 +02:00
Pavel Feldman
5ff1fadd7b
chore: apply only filtration to deps (#24268) 2023-07-17 16:48:52 -07:00
Yury Semikhatsky
f6540f89ea
chore(markdown): do not print details for flaky tests (#24264) 2023-07-17 16:09:59 -07:00
Yury Semikhatsky
15b9e5afdb
fix: print fatal and no snippet errors in markdown report (#24263) 2023-07-17 13:50:00 -07:00
Pavel Feldman
49c1f9eb02
feat(ui): run deps in UI mode if dep projects are checked (#24245) 2023-07-15 15:11:31 -07:00
Yury Semikhatsky
3616023cf6
chore: markdown report details (#24237) 2023-07-14 12:32:25 -07:00
Dmitry Gozman
97d55e275d
fix(locator): locator(locator) method uses internal:chain instead of >> (#24235)
Usually, we can just chain two locators with `>>` to implement
`Locator.locator(locator)`. However, this does not play nicely with more
advanced inner locators like `or` and `and`:

```ts
const child = page.locator('input').or(page.locator('button'));
page.locator('parent').locator(child);
```

One would expect the above to locate "input or button" inside a
"parent". However, currently it locates "input inside a parent" or
"button", because it's translated to `parent >> input >>
internal:or="button"`.

To fix this, we have to wrap inner locator into `internal:chain` and
query it separately from the parent.

Fixes #23724.
2023-07-14 12:21:45 -07:00
Dmitry Gozman
98f3ca05b9
fix(tracing): only access tracing state on the API calls, not inside trace operations (#24212)
References #23387.
2023-07-14 06:19:54 -07:00
Pavel Feldman
5d799606c3
chore: resolve top-level vs dependency after cli filtering (#24216) 2023-07-13 17:54:08 -07:00
Pavel Feldman
33bab3652d
fix(ui): bump min sidebar size (#24193) 2023-07-13 15:14:49 -07:00
Max Schmitt
57cca1d96e
Revert "fix: do not collide with other tests when test names have special chars (#23414)" (#24213)
This reverts commit 4b1b4dc23b.

https://github.com/microsoft/playwright/issues/24184

Reopens https://github.com/microsoft/playwright/issues/23386
2023-07-13 20:03:02 +02:00
Max Schmitt
b483bf9fcc
feat: add support for Debian 12 for Firefox/WebKit (#24206)
https://github.com/microsoft/playwright/issues/23532

---------

Signed-off-by: Max Schmitt <max@schmitt.mx>
2023-07-13 12:56:44 +02:00
Andrey Lushnikov
615f5afb2b
feat(firefox): roll Firefox to 1420 (#24205)
Fixes https://github.com/microsoft/playwright/issues/22753
2023-07-13 03:54:47 -07:00
Playwright Service
7787988043
feat(webkit): roll to r1872 (#24201)
Signed-off-by: Max Schmitt <max@schmitt.mx>
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Max Schmitt <max@schmitt.mx>
2023-07-13 11:07:33 +02:00
Playwright Service
04be72213b
feat(chromium-tip-of-tree): roll to r1132 (#24204)
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2023-07-13 10:58:13 +02:00
Dmitry Gozman
53feeaf270
fix(tracing): avoid trace file name collisions (#24191)
We have been optionally adding `-<number>` in multiple places, and these
might collide in various circumstances, for example: two contexts at the
same time, one of them has the second trace chunk.

References #23387.
2023-07-12 17:20:25 -07:00
Pavel Feldman
53bf1995db
chore: do not leak internal page handles after closing page (#24169)
Partial fix for https://github.com/microsoft/playwright/issues/6319

After this fix, the following scenario won't leak and the context state
(cookies, storage, etc) can be reused by the new page sessions:

```js
  for (let i = 0; i < 1000; ++i) {
    const page = await context.newPage();
    await page.goto('...');
    await page.close('...');
  }
```
2023-07-12 14:51:13 -07:00
Max Schmitt
a0b0752662
fix: encode launch options correctly when reusing browser (#24174)
Fixes https://github.com/microsoft/playwright/issues/24157
2023-07-12 16:40:55 +02:00
Playwright Service
6e02fda2a0
feat(firefox-beta): roll to r1419 (#24165)
Fixes https://github.com/microsoft/playwright/issues/24081

Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2023-07-12 03:28:20 -07:00
Dmitry Gozman
76d85c55cf
chore: remove unused code (#24167) 2023-07-11 15:08:05 -07:00
Pavel Feldman
067faa50d7
chore: migrate Promise.race to scopes to prevent leaks (#24160) 2023-07-11 10:38:08 -07:00
Dmitry Gozman
aeba083da0
fix(snapshots): match resources by method (#24145)
Fixes #24144.

Previously, we only matched by url, which confuses GET and HEAD requests
where the latter is usually zero-sized.

Also make sure that resources are sorted by their monotonicTime, since
that's not always the case in the trace file, where they are sorted by
the "response body retrieved" time.
2023-07-10 20:04:48 -07:00
Pavel Feldman
63915dc07a
feat(trace): render Node console messages in trace (#24139) 2023-07-10 18:36:28 -07:00
dependabot[bot]
36588ba98e
chore(deps): bump semver and @babel/core in /packages/playwright-test/bundles/babel (#24082)
Fixes https://github.com/microsoft/playwright/issues/23903

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: Max Schmitt <max@schmitt.mx>
2023-07-10 23:40:28 +02:00
Max Schmitt
1c2313d641
chore: upgrade esbuild to 0.18.11 (#24123) 2023-07-10 22:35:05 +02:00
Pavel Feldman
67ad2c2bf4
feat(ui): render all console / network messages in trace (#24115) 2023-07-10 12:56:56 -07:00
Andrey Lushnikov
94d6b1210b
fix: do not create empty directories for successful snapshot tests (#24127)
Fixes https://github.com/microsoft/playwright/issues/15600
2023-07-10 09:45:24 -07:00
Andrey Lushnikov
19474bef78
chore: update WebKit browser version to 17.0 (#24128) 2023-07-10 08:08:00 -07:00
Playwright Service
b4ffb848de
feat(webkit): roll to r1870 (#24119) 2023-07-10 08:09:08 +02:00
Pavel Feldman
50ba25e9a1
fix(trace): do not allow after w/o before (#24106)
Fixes https://github.com/microsoft/playwright/issues/24087,
https://github.com/microsoft/playwright/issues/23802
2023-07-07 17:16:26 -07:00
Andrey Lushnikov
a9560253f8
chore: cut 1.36.0 (#24104) 2023-07-07 13:01:17 -07:00
Playwright Service
9bca9f1b4f
feat(chromium): roll to r1071 (#24098)
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2023-07-07 16:51:03 +02:00
Playwright Service
90c92c5724
feat(firefox): roll to r1419 (#24091)
Fixes https://github.com/microsoft/playwright/issues/24080

Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2023-07-06 22:43:03 -07:00
Andrey Lushnikov
b9e68e22e0
feat: support Chromium installation on Debian 12 (#24090)
This adds Chromium support for both x86 and arm64 versions of Debian 12.

References https://github.com/microsoft/playwright/issues/24028
2023-07-06 22:41:36 -07:00
Andrey Lushnikov
9af2b518f2
fix: exclude tracesDir option from launchOptions fixture (#24086)
Fixes https://github.com/microsoft/playwright/issues/23645
2023-07-06 13:31:44 -07:00
Andrey Lushnikov
11dce8d127
feat(firefox): roll Firefox to 1417 (#24069)
Fixes https://github.com/microsoft/playwright/issues/23280
2023-07-06 12:18:02 -07:00
Pavel Feldman
0409bfca56
chore: ensure module deps in ct-core (#24056)
Fixes https://github.com/microsoft/playwright/issues/23823
2023-07-06 12:01:45 -07:00
Pavel Feldman
608e336dba
fix(error): create a step for raw runtime error (#24057)
Fix https://github.com/microsoft/playwright/issues/23850
2023-07-06 10:48:12 -07:00
Pavel Feldman
566b277ce8
fix(steps): only propagate soft errors up the hierarchy (#24054)
Fixes https://github.com/microsoft/playwright/issues/23979
2023-07-05 15:30:53 -07:00
Andrey Lushnikov
ea3a29eacd
feat(firefox): roll Firefox to 1415 (#24046)
Fixes https://github.com/microsoft/playwright/issues/23618
2023-07-05 11:58:38 -07:00
Pavel Feldman
df57fb594c
fix(trace): render items under expect.toPass (#24016)
Fixes: https://github.com/microsoft/playwright/issues/23942
2023-07-05 11:20:28 -07:00
Playwright Service
9f1f737acb
feat(chromium): roll to r1070 (#23991)
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2023-07-03 21:27:07 +00:00
Playwright Service
b3c4f45759
feat(webkit): roll to r1869 (#24011)
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2023-07-03 21:26:46 +00:00
Pavel Feldman
6343ea2795
feat(trace): allow scrolling the filmstrip (#24015)
Fixes https://github.com/microsoft/playwright/issues/23963
2023-07-03 13:03:33 -07:00
Patrick Shaw
6e78dcb7dc
fix: Allow portable bash paths for systems including NixOS (#23889)
Although very common, bash is not guaranteed to be located at
`/bin/bash`. NixOS is an example of this.

More commonly, `/bin/bash` can be quite out of date. An example of this
is MacOS's version of `bash`. This realistically won't affect Playwright
but it's worth noting. You can technically update MacOS's system version
of bash but you need elevated permissions to do so.

By using `/usr/bin/env bash` instead of `/bin/bash` we can execute
Playwright's bash scripts in like NixOS and generally improve the
selection behaviour for bash in other systems too.

Some discussion of why it's worth favouring `/usr/bin/env bash` over
`/bin/bash`:
- Discusses `/bin/bash` missing in NixOS:
https://discourse.nixos.org/t/add-bin-bash-to-avoid-unnecessary-pain/5673
- Some general commentary on why `/usr/bin/env bash` is favoured:
https://askubuntu.com/a/1402721
- Points out how old bash is in MacOS:
https://itnext.io/upgrading-bash-on-macos-7138bd1066ba

Improves situation at #5501
2023-07-03 06:27:06 -07:00
Dmitry Gozman
7e310f79af
chore: migrate builtin reporters to ReporterV2 (#23985)
This allows builtin reporters to handle stdio between onConfigure and
onBegin.

Fixes #23539.
2023-06-30 16:21:31 -07:00
Dmitry Gozman
86c1abd934
chore: introduce ReporterV2 interface (#23983) 2023-06-30 13:36:50 -07:00
Dmitry Gozman
92c738b14a
test: unflake some tests (#23984) 2023-06-30 13:08:18 -07:00
Dmitry Gozman
e28312ba63
chore: call onEnd(result) on InternalReporter (#23972)
Drive-by: fix watch mode not running global teardown.
2023-06-29 17:03:10 -07:00
Max Schmitt
a07626b804
feat(webkit): roll to r1868 (#23969)
GitHub had an outage so the PR didn't get created automatically.

Closes https://github.com/microsoft/playwright/pull/23931.
2023-06-29 23:27:48 +02:00
Max Schmitt
fef029e98e
docs: code snippet alignments (#23959) 2023-06-29 18:26:19 +02:00
Playwright Service
c2127595b8
feat(chromium-tip-of-tree): roll to r1128 (#23956)
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2023-06-29 15:17:16 +02:00
Dmitry Gozman
1d0b48f18b
fix(route): handle escapes in the glob pattern (#23932)
Fixes #23303.
2023-06-28 16:33:04 -07:00
Dmitry Gozman
1ab99fe1b8
feat(electron): support tracesDir option (#23947)
References #23620.
2023-06-28 16:32:16 -07:00
Dmitry Gozman
b0b429fed0
feat: support bigint in evaluates (#23930)
Fixes #22719.
2023-06-28 08:55:45 -07:00
Playwright Service
2808f3700a
feat(chromium-tip-of-tree): roll to r1127 (#23923)
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2023-06-27 15:25:01 +02:00
Max Schmitt
9980f054bc
docs: align Node.js code snippets with ESLint (#23916) 2023-06-27 11:53:53 +02:00
Max Schmitt
4b1b4dc23b
fix: do not collide with other tests when test names have special chars (#23414)
Fixes https://github.com/microsoft/playwright/issues/23386
2023-06-27 10:34:31 +02:00
Max Schmitt
dcdf38f119
chore: keep UI Mode running when used with browser mode (#23876)
This will keep UI Mode running in browser mode. When launched in normal
persistent context mode, we know when the persistent context closes, so
we can run the project teardown code.

Fixes https://github.com/microsoft/playwright/issues/23801
2023-06-26 22:21:44 +02:00
Max Schmitt
e1c220a37b
fix(trace-viewer): file path contains encoded characters (#23893)
This fixes:

```
npx playwright show-trace %20I%20Love%20Node.zip
```

Extracted from https://github.com/microsoft/playwright/pull/23414.
2023-06-26 18:13:40 +02:00
zhengjitf
6f67f6b52b
fix(chromium): can get correct orientation angle on non-mobile devices (#23796)
Fix #23772
2023-06-23 11:34:09 -07:00
Playwright Service
f85480a12e
feat(firefox-beta): roll to r1415 (#23866)
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Andrey Lushnikov <aslushnikov@gmail.com>
2023-06-23 07:03:20 -07:00
Dmitry Gozman
5821c547aa
fix(selector generator): use the same label definition as getByLabel (#23846)
This extracts `getElementLabels` helper function to be used both for
generating and querying.
2023-06-22 08:34:08 -07:00
Moritz Horstmann
bdac3e28a6
fix: best-effort support for TUXEDO OS (#23813)
TUXEDO OS is an Ubuntu based distribution built by the Linux computer
vendor TUXEDO.
2023-06-22 07:14:18 -07:00
Playwright Service
ddc0278d81
feat(chromium-tip-of-tree): roll to r1126 (#23858)
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2023-06-22 15:55:16 +02:00
Playwright Service
f7ecb7094d
feat(chromium): roll to r1069 (#23856)
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2023-06-22 15:54:56 +02:00
Playwright Service
f7ae17db09
feat(webkit): roll to r1865 (#23847)
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2023-06-22 12:07:49 +02:00
Dmitry Gozman
b154ff1190
fix(html reporter): do not print epilogue in list mode (#23822)
References #23817.
2023-06-21 17:53:52 -07:00
Max Schmitt
605dfde2be
chore: rename popout.html to snapshot.html in trace viewer (#23842)
Turns out its caused by a uBlockOrigin EasyList entry which thinks we
are an ad since we call ourselves "popout.html". See this entry:


e7883cfe74/easylist/easylist_general_block_popup.txt (L42)

Fixes https://github.com/microsoft/playwright/issues/23799
2023-06-21 21:10:50 +02:00
Ben Hofferber
752176fd23
feat(goto): better navigation error message (#23609)
While this log message is only a sanity check, it is still beneficial to
have a message that can better inform what is happening when this
occurs.
2023-06-21 11:10:35 -07:00
awatson-scottlogic
3777fc8b0f
docs(class-testoptions): fix launchOptions snippet (#23831) 2023-06-21 14:03:26 +02:00
Yury Semikhatsky
6a6ff9cf6a
feat: markdown report (#23819)
Simple markdown report generator. Can be used when posting updates to
GitHub PRs:

<img width="632" alt="image"
src="https://github.com/microsoft/playwright/assets/9798949/ea7e4bfa-477a-4cad-9cc3-00b1f8a314b1">
2023-06-20 12:11:32 -07:00
Andrey Lushnikov
1736479e41
fix: fix locator picker in Trace (#23820)
- make sure links are not clickable with enabled locator picker
- make sure locator picker state is preserved when switching actions
2023-06-20 11:39:21 -07:00
Playwright Service
270135faaf
feat(chromium-tip-of-tree): roll to r1125 (#23806)
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2023-06-20 16:15:22 +02:00
Playwright Service
7a060d13f0
feat(webkit): roll to r1864 (#23794)
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2023-06-20 09:29:15 +02:00
Dmitry Gozman
fe5c9dad4d
fix(locators): allow identical frameLocators inside and/or/has (#23740)
So, the following will work:

```
page.frameLocator('iframe').locator('span').or(page.frameLoactor('iframe').locator('div'))
```

The following will not work, because frame locators are not exactly the
same:

```
page.frameLocator('#iframe1').locator('span').or(page.frameLoactor('#iframe2').locator('div'))
```

Also improve the error message to be more readable and include the
locator.

Fixes #23697.
2023-06-19 15:22:26 -07:00
Dmitry Gozman
fbb5d48283
feat(expect): roll to v29.5.0 (#23629)
There is a breaking in change in the `MatcherContext` that is passed to
matcher functions, so we now have `!!this.isNot` in a few places. The
same could happen to custom matcher in the wild.

```ts
// Old
{
  isNot: boolean;
  promise: string;
}
```

```ts
// New
{
  isNot?: boolean;
  promise?: string;
}
```

Fixes #23612.
2023-06-19 15:18:59 -07:00
Dmitry Gozman
2c8dd67b0e
fix(test runner): improve error message for non-stable test titles (#23792)
Fixes #23779.
2023-06-19 14:13:11 -07:00
Sander
9d3edb0aa3
fix(ct): vue3 fallthrough events & callbacks (#23649)
closes:
https://github.com/microsoft/playwright/issues/23526#issuecomment-1583074280

closes: https://github.com/microsoft/playwright/issues/23435
2023-06-19 11:20:37 -07:00
vemv
380209af37
chore: log when websockets are proactively closed (#23689)
Closes https://github.com/microsoft/playwright/issues/23566

n.b., while that issue describes a fairly specific "use case", this
logging is simple and generic. It seems very plausible that it can help
diagnose all sorts of issues.

Cheers - V
2023-06-19 11:12:02 -07:00
Max Schmitt
0f9f863183
fix(codegen): generate no Enter keyboard events for textareas (#23775)
Fixes https://github.com/microsoft/playwright/issues/23774
2023-06-19 17:07:37 +02:00
Andrey Lushnikov
e171194c86
feat(firefox): roll Firefox to 1414 (#23768)
- roll Firefox stable to 1414
- roll Firefox beta to 1414

Fixes #23138
2023-06-17 12:10:20 -07:00
Dmitry Gozman
132a5a4bf5
fix(trace viewer): prefer latest resource with the same url (#23763)
When rendering snapshot, disregard earlier resources with the same url,
because it's most likely that the latest one was used for rendering.

An example would be reloading the page before the stylesheet has
finished loading. In this case, the stylesheet will be requested twice,
and the second copy that was not aborted should be used for the
snapshot.

Fixes #23709.
2023-06-17 06:58:16 -07:00
Yury Semikhatsky
f6d86c20f3
chore: run more reporter tests through blob report, some fixes (#23765) 2023-06-16 21:30:55 -07:00