Skip to content

Commit 05c7b17

Browse files
simonbairdclaude
andcommitted
Restore deleted snaps after make scenario_%
We're going this already for make feature_%. Use the same technique. Co-authored-by: Claude Code <noreply@anthropic.com>
1 parent 7c9c60f commit 05c7b17

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

Makefile

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -177,6 +177,10 @@ feature_%: ## Run acceptance tests for a single feature file, e.g. make feature_
177177
# (Replace spaces with underscores in the scenario name.)
178178
scenario_%: build ## Run acceptance tests for a single scenario, e.g. make scenario_inline_policy
179179
@cd acceptance && go test -test.run 'TestFeatures/$*'
180+
@# With UPDATE_SNAPS=true all the other snap files will be deleted. Let's put them back.
181+
@if [ -n "$$UPDATE_SNAPS" ]; then \
182+
git ls-files --deleted -- '../features/__snapshots__/*.snap' | xargs -r git checkout --; \
183+
fi
180184

181185
benchmark/%/data.tar.gz:
182186
@cd benchmark/$*

0 commit comments

Comments
 (0)