Mercurial > hg
view tests/test-permissions.t @ 20305:e5a2177d97f0
tests: stop tracking tests/gpg/random_seed
test-gpg.t left the random_seed file as modified. That was slightly confusing
... and it was accidentally changed in ea4996754d91.
The seed is created on demand and there is no reason to track it. There is also
no reason to leak state between test runs so we let the test clean up after
running.
author | Mads Kiilerich <madski@unity3d.com> |
---|---|
date | Mon, 20 Jan 2014 01:29:54 +0100 |
parents | e54a078153f7 |
children | 57b50abe2b24 |
line wrap: on
line source
#ifdef unix-permissions no-root $ hg init t $ cd t $ echo foo > a $ hg add a $ hg commit -m "1" $ hg verify checking changesets checking manifests crosschecking files in changesets and manifests checking files 1 files, 1 changesets, 1 total revisions $ chmod -r .hg/store/data/a.i $ hg verify checking changesets checking manifests crosschecking files in changesets and manifests checking files abort: Permission denied: $TESTTMP/t/.hg/store/data/a.i [255] $ chmod +r .hg/store/data/a.i $ hg verify checking changesets checking manifests crosschecking files in changesets and manifests checking files 1 files, 1 changesets, 1 total revisions $ chmod -w .hg/store/data/a.i $ echo barber > a $ hg commit -m "2" trouble committing a! abort: Permission denied: $TESTTMP/t/.hg/store/data/a.i [255] $ chmod -w . $ hg diff --nodates diff -r 2a18120dc1c9 a --- a/a +++ b/a @@ -1,1 +1,1 @@ -foo +barber $ chmod +w . $ chmod +w .hg/store/data/a.i $ mkdir dir $ touch dir/a $ hg status M a ? dir/a $ chmod -rx dir $ hg status dir: Permission denied M a Reenable perm to allow deletion: $ chmod +rx dir $ cd .. #endif