Skip to content

Commit b74da46

Browse files
committed
Add logic for intentional failures
1 parent e16df5d commit b74da46

File tree

3 files changed

+12
-2
lines changed

3 files changed

+12
-2
lines changed

transcripts/share-apis/sync/ambiguous-component-ordering.md renamed to transcripts/share-apis/sync/error-ambiguous-component-ordering.md

File renamed without changes.

transcripts/share-apis/sync/ambiguous-component-ordering.output.md renamed to transcripts/share-apis/sync/error-ambiguous-component-ordering.output.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ ambiguous/main> update
2929

3030
Try to push, this should be rejected.
3131

32-
``` ucm :error
32+
``` ucm
3333
ambiguous/main> push @transcripts/ambiguous/main
3434
```
3535

transcripts/share-apis/sync/run.zsh

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,5 +11,15 @@ for transcript in $(ls *.md | grep -v '^prelude.md$' | grep -v 'output.md$') ; d
1111
pg_reset_fixtures
1212

1313
echo "Running $transcript"
14-
transcript_ucm transcript "$transcript"
14+
if [[ "$transcript" == error* ]]; then
15+
if transcript_ucm transcript "$transcript"; then
16+
echo "Transcript $transcript was expected to fail but succeeded"
17+
exit 1
18+
else
19+
echo "Transcript $transcript failed as expected"
20+
fi
21+
else
22+
# Add logic here for non-error transcripts
23+
transcript_ucm transcript "$transcript"
24+
fi
1525
done

0 commit comments

Comments
 (0)