##// END OF EJS Templates
Do not use osutil.c with python 2.4 and Windows (issue1364)...
Do not use osutil.c with python 2.4 and Windows (issue1364) Windows python 2.4 os.stat() reports times including DST offset, while osutil.c reports the correct value, which makes status() systematically compare files content. This bug is fixed in python 2.5. Using osutil.py instead of osutil.c is 4x times slower on large repositories but current code is completely unusable. Given few people are likely to use python 2.4 on Windows this solution was considered a good trade-off compared to more invasive solutions trying to address the offset issue.

File last commit:

r4140:193e0f8d default
r10521:bde1bb25 stable
Show More
test-abort-checkin
28 lines | 553 B | text/plain | TextLexer
/ tests / test-abort-checkin
Thomas Arendsen Hein
Add test mq keeping a reference to localrepo which can't remove journal on exit.
r2726 #!/bin/sh
Alexis S. L. Carvalho
test-abort-checkin: use a hook to abort the commit...
r4140 cat > abortcommit.py <<EOF
from mercurial import util
def hook(**args):
raise util.Abort("no commits allowed")
def reposetup(ui, repo):
repo.ui.setconfig("hooks", "pretxncommit.nocommits", hook)
EOF
abspath=`pwd`/abortcommit.py
Thomas Arendsen Hein
Make tests append settings to $HGRCPATH instead of $HGTMP/.hgrc...
r2990 echo "[extensions]" >> $HGRCPATH
echo "mq=" >> $HGRCPATH
Alexis S. L. Carvalho
test-abort-checkin: use a hook to abort the commit...
r4140 echo "abortcommit = $abspath" >> $HGRCPATH
Thomas Arendsen Hein
Add test mq keeping a reference to localrepo which can't remove journal on exit.
r2726
hg init foo
cd foo
echo foo > foo
hg add foo
# mq may keep a reference to the repository so __del__ will not be called
# and .hg/journal.dirstate will not be deleted:
Alexis S. L. Carvalho
test-abort-checkin: use a hook to abort the commit...
r4140 hg ci -m foo
hg ci -m foo
Thomas Arendsen Hein
Add test mq keeping a reference to localrepo which can't remove journal on exit.
r2726
exit 0