mirror of
https://github.com/microsoft/playwright.git
synced 2024-12-15 06:02:57 +03:00
854f321532
feat(api): add explicit async testInfo.attach We add an explicit async API for attaching file paths (and Buffers) to tests that can be awaited to help users ensure they are attaching files that actually exist at both the time of the invocation and later when reporters (like the HTML Reporter) run and package up test artifacts. This is intended to help surface attachment issues as soon as possible so you aren't silently left with a missing attachment minutes/days/months later when you go to debug a suddenly breaking test expecting an attachment to be there. NB: The current implemntation incurs an extra file copy compared to manipulating the raw attachments array. If users encounter performance issues because of this, we can consider an option parameter that uses rename under the hood instead of copy. However, that would need to be used with care if the file were to be accessed later in the test. |
||
---|---|---|
.. | ||
build | ||
docker | ||
doclint | ||
flakiness-dashboard | ||
generate_types | ||
linux-browser-dependencies | ||
protocol-types-generator | ||
testserver | ||
avd_install.sh | ||
avd_recreate.sh | ||
avd_start.sh | ||
avd_test.js | ||
build_android_driver.sh | ||
bump_package_versions.js | ||
check_chromium_cdn.js | ||
check_deps.js | ||
copyright.js | ||
draft_release_notes.sh | ||
generate_channels.js | ||
generate_dotnet_channels.js | ||
lint_tests.js | ||
list_closed_issues.sh | ||
list_packages.js | ||
markdown.js | ||
pack_package.js | ||
prepare_packages.js | ||
print_versions.js | ||
publish_all_packages.sh | ||
roll_browser.js | ||
upload_flakiness_dashboard.sh | ||
video_stress.js |