Commit Graph

2816 Commits

Author SHA1 Message Date
Pavel Feldman
51a774f8a3
chore: include log in matcherResult (#27164) 2023-09-21 16:23:46 -07:00
Dmitry Gozman
1857a3fb56
fix(evaluate): make sure to try/catch toJSON access (#27238) 2023-09-21 13:31:28 -07:00
Dmitry Gozman
14a3659071
test: speed up installation tests by not downloading from cdn multiple times (#27220) 2023-09-21 12:40:18 -07:00
Yury Semikhatsky
0bc55fac91
test: unskip "should capture full viewport" (#27233)
This is fixed by
https://github.com/microsoft/playwright-browsers/pull/643

Fixes https://github.com/microsoft/playwright-browsers/issues/637
2023-09-21 11:20:18 -07:00
Dmitry Gozman
b9509b3ec6
Revert "feat(evaluate): serialize map and set (#26730)" (#27219)
This reverts commit ee203b782c.

References #24040.
Fixes #27181.
2023-09-20 18:31:09 -07:00
Dmitry Gozman
2af7d672ef
fix(tracing): bump trace version to V5, migrate V4 traces to consoleMessage.args (#27162)
This moves the fix in #27095 from `modernize` to `appendEvent`. The
reason is that `trace V4` is used both for older traces that do not have
`consoleMessage.args` and the new ones with `args`. Since we do not call
`modernize` for traces of the same version, the original fix does not
help in this case.

Fixes #27144.
2023-09-19 16:21:09 -07:00
Yury Semikhatsky
88038f1b00
fix: do not throw from fetch when response has invalid cookie (#27192)
Cookie value is limited by 4096 characters in the browsers. If
setCookies failed we try setting each cookie individually just in case
only some of them are bad.

Fixes https://github.com/microsoft/playwright/issues/27165
2023-09-19 16:18:16 -07:00
Dmitry Gozman
bb4268d165
fix(locators): do not escape regular expressions with u or v flag (#27188)
Fixes #27163.
2023-09-19 13:16:50 -07:00
Playwright Service
f064fb6840
feat(firefox-beta): roll to r1425 (#27128)
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Andrey Lushnikov <aslushnikov@gmail.com>
2023-09-19 00:31:58 -07:00
Yury Semikhatsky
8964587d18
test: update webkit test expectations after last roll (#27155)
https://github.com/microsoft/playwright/issues/26992 was fixed by
https://github.com/microsoft/playwright-browsers/pull/635.

Reference https://github.com/microsoft/playwright-browsers/issues/637
Fixes https://github.com/microsoft/playwright/issues/26992
2023-09-18 09:57:18 -07:00
Pavel Feldman
955be6bd61
chore: populate matcherResult for toHaveScreenshot (#27136)
Ref #26929
2023-09-18 09:12:23 -07:00
Pavel Feldman
9fe037fb63
chore: populate matcherResult in web assertions (#27133)
Ref https://github.com/microsoft/playwright/issues/26929
2023-09-16 14:24:10 -07:00
Dmitry Gozman
3bcf9687e6
fix(test runner): make sure auto worker fixtures run before auto test fixtures (#27131)
Fixes #27114.
2023-09-15 14:51:31 -07:00
Pavel Feldman
527d260cbf
chore: hide tracing calls from traces (#27096) 2023-09-15 12:55:49 -07:00
Andrey Lushnikov
a34030be80
browser(firefox): support relative paths for firefox videos (#27099)
Firefox protocol requires absolute paths for video recording.

Fixes https://github.com/microsoft/playwright/issues/27086
2023-09-15 10:26:20 -07:00
Max Schmitt
0d44405762
fix: custom expect matchers on Locator/Page/APIResponse instance (#27117)
Fixes https://github.com/microsoft/playwright/issues/27113
2023-09-15 18:05:44 +02:00
Yury Semikhatsky
ebf6a08290
fix: list tests only once (#27103)
Fixes #27087
2023-09-14 20:00:30 -07:00
Max Schmitt
26cbe69442
test: use intermediate merge report for JSON repoter (#27092) 2023-09-15 04:36:15 +02:00
Dmitry Gozman
b3edf8e562
fix(har): handle invalid Expires/Max-Age (#27098)
Fixes #27073.
2023-09-14 17:06:56 -07:00
David Paquette
3170963f42
fix: render JUnit attachment paths relative to outputFile (#27024) 2023-09-14 12:58:09 -07:00
Dmitry Gozman
603861c48d
fix: revert toMatchSnapshot deprecation (#27089)
- This reverts commit
8348f66107
landed in #26718.
- Update docs to point towards `toHaveScreenshot`.
2023-09-14 12:52:41 -07:00
Max Schmitt
aa929bff3b
test: unflake 'filter should update stats' test (#27085)
It's not possible to calculate the total test duration of the tests in
the UI, since our `msToString` function is lossy. This patch unflakes
the
[test](https://github.com/microsoft/playwright/actions/runs/6183832112/job/16787806162?pr=27074#step:7:254)
when it took longer than a second to start, by writing the test-ids to
the DOM, getting them into the Node.js process, and calculating their
test duration sum based on the JSON report.

Drive-by: I found a bug that we used the JSON report from the main
test-runner process rather than from the merge process, so the test IDs
were still old. (Without that change the `useIntermediateMergeReport`
tests were not passing.
2023-09-14 19:51:05 +02:00
Max Schmitt
4431a8366d
fix: collect stdio from forked processes (#27074)
A summary about the attempts we tried in
https://github.com/microsoft/playwright/pull/26931 for
https://github.com/microsoft/playwright/issues/26859 and
https://github.com/microsoft/playwright/issues/24591.

1. attempt: collect all the stdio from the worker host.
- this made it hard to capture the live console logs for the live trace
2. attempt: collect all the stdio from the worker host, but keep
proxying `process.{stdout,stderr}.write`.
- this solved the live console logs problem, since we could still listen
on them
- we found out about a race that the stdout/stderr streams can still
buffer data while the test already had finished
- we created a best effort flush implementation but didn't like the
complexity it introduced to the project
3. attempt: keep things like they are but also listen to stdio from the
worker host
- this solves the race of console.log in the test (things stay like they
are)
    - this keeps live trace working (things stay like they are)
- a known pitfall is that it could result in logs which don't end up in
the reporter onStdOut/onStdErr, but it is already a significant
improvement over how it was before.
      - before: they were not getting displayed
- after: they are getting displayed and there is a low likelihood that
they don't end up in the reporter API if the write happens slightly
before a test finished.

Closes #26931
Fixes #26859
Fixes #24591
2023-09-14 18:34:26 +02:00
Dmitry Gozman
f9298cfff6
fix(tracing): unclash trace names between test and hooks (#27063)
Fixes #27048.
2023-09-13 19:56:40 -07:00
Andrey Lushnikov
45d2a36453
chore: roll stable test runner to 1.38 beta (#27066) 2023-09-13 16:01:06 -07:00
Yury Semikhatsky
1424185c23
test: init script runs onces in iframes (#27057)
Failing test for #26992.
2023-09-13 09:46:59 -07:00
Andrey Lushnikov
64bf2a624f
test: fix webkit test on Darwin (#27029) 2023-09-12 15:01:44 -07:00
Pavel Feldman
02c72e545b
feat(onEnd): allow overriding the exit code (#27010)
Fixes: https://github.com/microsoft/playwright/issues/26858
2023-09-12 13:37:30 -07:00
Max Schmitt
d0945192a4
feat: make it possible to filter by column in HTML report (#27020) 2023-09-12 22:13:15 +02:00
Yury Semikhatsky
700b310150
fix(fetch): restore from empty storage state (#27025)
Fixes #26833
2023-09-12 13:11:18 -07:00
Dmitry Gozman
d9eabda09d
fix(locators): escape quotes in regular expressions (#27002)
Fixes #26974.
2023-09-11 15:49:04 -07:00
Max Schmitt
01ab703400
test: restore useIntermediateMergeReport=true test mode in html tests (#26989)
This got accidentally removed in
https://github.com/microsoft/playwright/pull/26799.
2023-09-11 09:14:05 -07:00
Yury Semikhatsky
2feae015aa
chore: remove details from markdown reports (#26961)
- remove error details from the reports
- collapse flaky tests by default
- limit comment to 65365 character

GitHub API has comment length limit 65536 chars:
```
Unhandled error: HttpError: Validation Failed: {"resource":"IssueComment","code":"unprocessable","field":"data","message":"Body is too long (maximum is 65536 characters)"}
```
2023-09-08 17:49:34 -07:00
Dmitry Gozman
186f86905c
chore: make @playwright/test depend on playwright (#26946) 2023-09-08 14:23:35 -07:00
Yury Semikhatsky
0213fef484
test: unskip passing test (#26960)
The functionality was fixed in
[webkit](https://github.com/microsoft/playwright-browsers/pull/625) and
should be available with [recent
roll](https://github.com/microsoft/playwright/pull/26953).

Fixes #26876
2023-09-08 12:57:32 -07:00
Dmitry Gozman
e6d9b2a818
test: add installation tests for yarn and pnpm (#26937) 2023-09-08 10:06:31 -07:00
Yury Semikhatsky
fd28e8d801
test: reset view scale after navigation (#26939)
Failing test for #26876
2023-09-08 08:58:07 -07:00
Pavel Feldman
167c35ca66
chore: store scroll positions in trace viewer (#26938) 2023-09-07 17:14:39 -07:00
Playwright Service
bcf59ed721
feat(webkit): roll to r1905 (#26909) 2023-09-07 07:41:46 +02:00
Pavel Feldman
61a1924328
chore: align recorder drawer with trace viewer (#26922) 2023-09-06 17:13:25 -07:00
Pavel Feldman
d65da74b8f
fix(trace): allow typing in selector w/ frames (#26919) 2023-09-06 16:14:40 -07:00
Max Schmitt
f71df9fb50
chore: introduce sdkLanguage based userDataDir misuse error (#26894)
Fixes https://github.com/microsoft/playwright-python/issues/2059

---------

Signed-off-by: Max Schmitt <max@schmitt.mx>
Co-authored-by: Dmitry Gozman <dgozman@gmail.com>
2023-09-06 22:58:44 +02:00
Dmitry Gozman
361038c950
feat: rename PageError to WebError (#26913) 2023-09-06 12:40:53 -07:00
Pavel Feldman
b4012df160
fix(trace): make locator picker work for iframes (#26883)
Fixes https://github.com/microsoft/playwright/issues/26878
2023-09-06 09:44:47 -07:00
Yury Semikhatsky
f045e13e00
test: contextmenu on right click (#26885)
Reference https://github.com/microsoft/playwright/issues/26515
2023-09-05 16:12:17 -07:00
Dmitry Gozman
740472ce8f
fix(trace viewer): retain currentSrc of all images (#26841)
When `<source>` or `srcset=` are involved, the actual image src is
determinted at runtime based on factors like `devicePixelRatio` and
media queries that depend on width/height.

Since these factors may differ in the Trace Viewer itself, we should
preserve the `currentSrc`, use it as an actual `src`, and disable
various `<source>` and `srcset=`.
2023-09-05 12:48:07 -07:00
Pavel Feldman
8c494e2519
chore: add log/error tabs and counters (#26843) 2023-09-01 20:12:05 -07:00
Yury Semikhatsky
ce3e0dcf84
test: unskip test in headless (#26844)
Reference https://github.com/microsoft/playwright/issues/22617
2023-09-01 17:26:23 -07:00
Pavel Feldman
a339bead09
chore: implement faster ansi2html format for console (#26826) 2023-09-01 09:09:47 -07:00
Pavel Feldman
4948920437
fix(ui): do not log from beforeAll twice (#26799)
Fixes https://github.com/microsoft/playwright/issues/26790
2023-08-31 17:34:15 -07:00