Skip to content

Commit

Permalink
Add Superfluous Snapshots workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
tinder-garricnahapetian committed Jan 27, 2024
1 parent 8659841 commit 1b19ecb
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 0 deletions.
34 changes: 34 additions & 0 deletions .github/workflows/superfluous-snapshots.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: Superfluous Snapshots

on:
push:
branches: [ main ]
pull_request:
branches: [ main ]

env:
DEVELOPER_DIR: /Applications/Xcode_15.0.app/Contents/Developer
SWIFT_STRICT_CONCURRENCY: complete

jobs:
swift:
name: Superfluous Snapshots
runs-on: macos-13
env:
SIMULATOR: iPhone 14
steps:
- name: Checkout source
uses: actions/checkout@v3
- name: Delete snapshots
run: make delete-snapshots
- name: Record snapshots
run: xcodebuild test -skipPackageUpdates -scheme "Layout" -destination "name=iPhone 14 Pro,OS=latest"
- name: Detect superfluous snapshots
run: |
if [ -z "$(git status --porcelain)" ]
then
echo "No superfluous snapshots detected."
else
echo "Superfluous snapshots detected."
exit 1
fi
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
suprious-snapshot

0 comments on commit 1b19ecb

Please sign in to comment.