14509 Commits

Author SHA1 Message Date
Anthony Roberts
71c43693ac
feat(reporter): add copy button for annotations (#31790)
Adds a copy-to-clipboard button for each annotation so that text can be
copied easily.
This re-uses the existing `CopyToClipboard` component and adds a `small`
variant that can be used inline. The icon size and colour have been
chosen to avoid being overwhelming when used inline.

Related to #30141 
I opted not to introduce the hover behaviour from #30749 as it's less
discoverable, but can understand why that might be favourable. Certainly
open to suggestions 😄

<img width="379" alt="Screenshot 2024-07-22 at 3 23 53 PM"
src="https://github.com/user-attachments/assets/3b9998cf-2e8d-40c9-9c8a-64eab3a9ed2e">
2024-09-16 07:57:11 -07:00
Max Schmitt
762e954599
devops: update GitHub Actions (#32634)
Fixes: 
<img width="2205" alt="image"
src="https://github.com/user-attachments/assets/0cd09784-6f0b-4331-9e08-315cf8614031">

For future reference: `pip install github-actions-cli &&
github-actions-cli update-actions --update`
2024-09-16 15:43:42 +02:00
Dmitry Gozman
268357238a
fix(expect): respect custom message in expect.poll (#32603)
Fixes #32582.
2024-09-16 00:10:06 -07:00
Max Schmitt
c24ad36f86
docs(docker): fix Docker container permissions (#32621) 2024-09-16 07:39:36 +02:00
Simon Knott
aeb4d182f7
feat(tracing): add .pwtrace to trace file extension (#32581)
Closes https://github.com/microsoft/playwright/issues/32226

I've updated every mention of `.trace.zip` except for the release notes.
2024-09-14 10:17:07 +02:00
Yury Semikhatsky
34876e9291
chore: cookies in intercepted bidi requests (#32623) 2024-09-13 18:29:35 -07:00
Matthew Jee
f2a974b045
feat(api): add method to force garbage collection (#32383) 2024-09-13 23:09:36 +02:00
Playwright Service
5b28d2a84c
feat(firefox): roll to r1464 (#32614)
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2024-09-13 18:12:43 +02:00
Playwright Service
b82100adf5
feat(firefox-beta): roll to r1464 (#32615)
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2024-09-13 18:12:35 +02:00
Max Schmitt
79cba7d704
chore: introduce option overrides on context/browser (#32606) 2024-09-13 17:34:34 +02:00
Simon Knott
9bb1c86f93
feat(test runner): don't run tests on --watch start (#32583)
Closes https://github.com/microsoft/playwright/issues/32580.
2024-09-13 17:24:38 +02:00
Max Schmitt
9e99c86f00
chore: unhide merge-reports command (#32605) 2024-09-13 16:13:23 +02:00
Playwright Service
e3370c9eb0
feat(webkit): roll to r2075 (#32610)
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2024-09-13 15:13:11 +02:00
Simon Knott
48c7fb6b06
feat(library): accept FormData in fetch (#32602)
Closes https://github.com/microsoft/playwright/issues/26520 by accepting
`FormData`, which became stable in Node.js in v21.
2024-09-13 13:21:02 +02:00
Pavel Feldman
cd4dabef8b
chore: remove stray codegen signal handling (#32599) 2024-09-12 14:38:23 -07:00
Pavel Feldman
7e3348eb0e
chore: recorder is trace viewer experiment (#32598) 2024-09-12 13:39:44 -07:00
Pavel Feldman
de08e729ae
chore: move recorder trace to action collector (#32597) 2024-09-12 12:42:28 -07:00
Pavel Feldman
d051495c7a
chore: perform double click while recording (#32576) 2024-09-12 11:40:44 -07:00
Max Schmitt
5e086be36b
chore: freeze ffmpeg on macOS-12 (#32596) 2024-09-12 20:32:34 +02:00
Max Schmitt
8e82f53ceb
test: unskip various proxy tests (#32595)
Unskipping of various tests and revert the rest of
https://github.com/microsoft/playwright/pull/6350 since the upstream bug
has been fixed.
2024-09-12 20:31:22 +02:00
Simon Knott
ef4be6afff
feat(test runner): make expect.extend immutable (#32366)
Changes `expect.extend` behaviour so that it doesn't mutate the global
instance and behaves closer to what users expect. This is formally a
breaking change, and I had to remove a test that asserts the breaking
behaviour.

TODO:
- [x] decide wether this is a separate method or a flag for
`expect.extend`
- [x] figure out if we need to change docs
2024-09-12 19:56:38 +02:00
Simon Knott
c9f3eb158e
feat(ui): highlight output toggle button if terminal contains error (#32392)
Closes https://github.com/microsoft/playwright/issues/32368

<img width="412" alt="Screenshot 2024-08-30 at 13 22 39"
src="https://github.com/user-attachments/assets/76cadcd9-e92a-44d9-80fc-b4e04702e71e">
2024-09-12 19:40:40 +02:00
Playwright Service
470b1b4922
feat(chromium-tip-of-tree): roll to r1259 (#32588)
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2024-09-12 13:46:33 +02:00
Playwright Service
b1b33efebb
feat(chromium): roll to r1135 (#32591)
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2024-09-12 13:46:15 +02:00
Max Schmitt
491678ada6
docs: release note fixes for 1.47 (#32589) 2024-09-12 12:51:30 +02:00
Teng Yang
6a0009f9ed
fix(trace-viewer): fix ui issue on network request details (#32553) 2024-09-12 12:26:51 +02:00
Max Schmitt
dc5bbbf295
devops: remove macos-12 bots (#32587)
We stopped supporting macos-12 in 1.45, see the release notes and
https://github.com/microsoft/playwright/pull/31283.
2024-09-12 11:27:47 +02:00
Max Schmitt
a838e74c61
devops: move macos runners to public infra (#32586) 2024-09-12 10:50:05 +02:00
Yury Semikhatsky
d1926e2f9b
chore: do not store project name in expectations (#32575) 2024-09-11 15:15:10 -07:00
Yury Semikhatsky
678c454fea
test: update bidi expectations from recent run (#32574) 2024-09-11 14:59:28 -07:00
Yury Semikhatsky
fd1f32556b
chore: run all tests with bidi by default (#32572)
Only use expectation files on CI to save resources
2024-09-11 14:24:32 -07:00
Dmitry Gozman
1981989aef
docs: mention variability of media codecs between platforms (#32569)
References #32558.
2024-09-11 13:35:17 -07:00
Yury Semikhatsky
a8103abee6
chore: incremental bidi expectation update, ff expectations (#32570)
* Do not override expectations for the tests that didn't run or already
had expectations
* Sort expectations alphabetically
* Add firefox expectations
2024-09-11 13:33:25 -07:00
Dmitry Gozman
29a0f49e9b
chore(test runner): simplify code around running tasks (#32557)
This avoids complex boilerplate around `onConfigure`/`onEnd`/`onExit`
and managing the resulting status.
2024-09-11 13:09:00 -07:00
Playwright Service
6f52834f74
feat(webkit): roll to r2073 (#32563)
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2024-09-11 20:39:01 +02:00
Max Schmitt
7458c3292c
fix(test-runner): do not consider retries for maxFailures (#32533)
Fixes https://github.com/microsoft/playwright/issues/26350
2024-09-11 20:35:26 +02:00
Yury Semikhatsky
1f0514536e
chore: add bidi test expectations in separate file (#32549)
Based on the expectations the tests that are expected to timeout or fail
will be skipped to save resources. The expectations can be manually
updated when corresponding feature is fixed.
2024-09-11 08:28:29 -07:00
Playwright Service
aaac57b948
feat(webkit): roll to r2072 (#32550)
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2024-09-11 13:02:03 +02:00
Dmitry Gozman
7335fa602c
fix(trace viewer): do not show multiple action points in iframes (#32537)
When action has an input target, we assume there is a target element in
one of the frames and show action point in its center.

Fixes #32453.
2024-09-11 03:04:03 -07:00
Yury Semikhatsky
a4bd551597
docs: TestInfo.titlePath does not include project (#32548) 2024-09-10 16:52:12 -07:00
Dmitry Gozman
356517cddb
chore(test runner): extract LastRunReporter (#32540) 2024-09-10 12:14:44 -07:00
Dmitry Gozman
b5d968fa0e
chore: make ReporterV2 a partial interface (#32532)
This makes it easier to write reporters by avoding empty methods.
2024-09-10 06:08:54 -07:00
Simon Knott
ec40890fd8
fix(tracing): use page swap timestamp to find closest screenshot (#32512)
Follow-up to https://github.com/microsoft/playwright/pull/32248. When we
have it, we should use the page swap timestamp we get from Chromium to
find the closest screenshot.
2024-09-10 14:32:33 +02:00
Rui Figueira
f8562e4ca7
chore: improve error message when Array.toJSON misbehaves (#32508)
Fixes: #32507
2024-09-10 04:14:24 -07:00
Max Schmitt
9fa06be49e
fix(ct): throw error if inline component is getting mounted (#32531)
What was happening?
- When we use CT, we go over the test files, look at the imports using
`tsxTransform.ts` and store them inside a map, these we feed into the
import registry which we build using Vite and have access inside the
browser
- In case of an inline component in the same file as where the test file
is, this is not happening.
- jsx-runtime via babel kicks in, transforms every JSX component in
something like that:

```
{
  __pw_type: 'jsx',
  type: [Function: MyInlineComponent],
  props: { value: 'Max' },
  key: undefined
}
```

this then gets passed into `wrapObject` which maps any function from the
Node.js side into expose function calls so they work inside the browser.
The assumption for `wrapObject` was to do it mostly for callbacks. So it
does for `type` - which is actually our component. We then pass this to
the React render function, which calls back the exposed function but we
never return anything, so it mounts `undefined`.

---

While there have been experiments from certain vendors to get the
'client only' code inside a server side file, we should throw for now to
not confuse users. We might revisit this in the future since Babel / TSX
doesn't support it outside of the box.

Fixes https://github.com/microsoft/playwright/issues/32167
2024-09-10 11:15:20 +02:00
Playwright Service
8995ace825
feat(firefox-beta): roll to r1463 (#32529) 2024-09-10 08:57:40 +02:00
Yury Semikhatsky
c8a72d63ad
chore: run bidi firefox tests on ci (#32527) 2024-09-09 17:22:19 -07:00
Pavel Feldman
6d5889a52c
chore: revert the matcherResult in API (#32524) 2024-09-09 16:44:32 -07:00
Dmitry Gozman
ae118674b8
fix(test runner): allow directory imports with path mapping (#32491)
We now hopefully align with `moduleResolution: bundler` tsconfig option,
allowing directory imports in every scenario, and allowing proper module
imports when not going through the type mapping.

This regressed in #32078. Fixes #32480, fixes #31811.
2024-09-09 14:01:20 -07:00
Dmitry Gozman
6bb005db85
fix(test runner): improve error message when not able to parse tsconfig (#32526) 2024-09-09 14:01:02 -07:00