mirror of
https://github.com/Comfy-Org/ComfyUI_frontend.git
synced 2026-01-26 19:09:52 +00:00
This pull request updates the workflow for managing Playwright expectation snapshots in `.github/workflows/pr-update-playwright-expectations.yaml`. The main focus is to improve how changed snapshot files are handled, ensuring directory structures are correct and only necessary files are processed and committed. The most important changes are grouped below: **Snapshot file handling improvements:** * When copying changed snapshot files, the workflow now strips the `browser_tests/` prefix to avoid double nesting in the staging directory. This ensures the directory structure remains correct when files are merged back. * During the merging step, the script clarifies that files are already in the correct structure (without the `browser_tests/` prefix), so they can be copied directly into `browser_tests/`. **Workflow and commit logic enhancements:** * The snapshot artifact download step is renamed for clarity, indicating that only changed snapshot files are downloaded from shards. * The commit step is improved to check for actual changes in `browser_tests/` before attempting to commit and push. It sets an output variable (`has-changes`) to control subsequent steps, adds more informative logging, and only pushes when there are changes. * The "Add Done Reaction" step is now conditional on both the event type and whether there were changes to commit, preventing unnecessary reactions. ┆Issue is synchronized with this [Notion page](https://www.notion.so/PR-6252-Hotfix-CI-update-test-expectations-2966d73d36508131968ee5a7f04ff787) by [Unito](https://www.unito.io) --------- Co-authored-by: github-actions <github-actions@github.com>