From 12fd19dd4d2a31847eb0e4a820ea1193002301e6 Mon Sep 17 00:00:00 2001 From: Liam DeBeasi Date: Fri, 1 Apr 2022 12:06:40 -0400 Subject: [PATCH] chore(playwright): screenshots are now ignored locally (#25043) --- .../actions/update-reference-screenshots/action.yml | 8 +++++++- .gitignore | 1 + 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/.github/workflows/actions/update-reference-screenshots/action.yml b/.github/workflows/actions/update-reference-screenshots/action.yml index 927258c787..2573e1175b 100644 --- a/.github/workflows/actions/update-reference-screenshots/action.yml +++ b/.github/workflows/actions/update-reference-screenshots/action.yml @@ -25,10 +25,16 @@ runs: # Configure user as Ionitron # and push only the changed .png snapshots # to the remote branch. + # Screenshots are in .gitignore + # to prevent local screenshots from getting + # pushed to Git. As a result, we need --force + # here so that CI generated screenshots can + # get added to git. Screenshot ground truths + # should only be added via this CI process. run: | git config user.name ionitron git config user.email hi@ionicframework.com - git add src/\*.png + git add src/\*.png --force git commit -m "chore(): add updated snapshots" git push shell: bash diff --git a/.gitignore b/.gitignore index 36554c03d7..c4a911257c 100644 --- a/.gitignore +++ b/.gitignore @@ -70,5 +70,6 @@ angular/build/ # playwright core/test-results/ core/playwright-report/ +core/**/*-snapshots .npmrc