sapling/eden/scm/tests/test-journal-exists.t
Jun Wu 75a8173a10 tests: enable chg for 572 tests
Summary:
Add `#chg-compatible` to 572 tests that seem to pass with chg enabled.
This should make them run faster.

Reviewed By: xavierd

Differential Revision: D18870507

fbshipit-source-id: fe895e733efffc9286cd3d17c7a156c803124395
2019-12-09 15:26:29 -08:00

44 lines
1.0 KiB
Perl

#chg-compatible
$ setconfig extensions.treemanifest=!
$ hg init
$ echo a > a
$ hg ci -Am0
adding a
$ hg -q clone . foo
$ touch .hg/store/journal
$ echo foo > a
$ hg ci -Am0
abort: abandoned transaction found!
(run 'hg recover' to clean up transaction)
[255]
$ hg recover
rolling back interrupted transaction
checking changesets
checking manifests
crosschecking files in changesets and manifests
checking files
1 files, 1 changesets, 1 total revisions
Check that zero-size journals are correctly aborted:
#if unix-permissions no-root
$ hg bundle -qa repo.hg
$ chmod -w foo/.hg/store/00changelog.i
$ hg -R foo unbundle repo.hg
adding changesets
abort: Permission denied: $TESTTMP/foo/.hg/store/.00changelog.i-* (glob)
(current process runs with uid 42)
($TESTTMP/foo/.hg/store/.00changelog.i*: mode 0o52, uid 42, gid 42) (glob)
($TESTTMP/foo/.hg/store: mode 0o52, uid 42, gid 42)
[255]
$ if test -f foo/.hg/store/journal; then echo 'journal exists :-('; fi
#endif