tests/test-gpg
author Sol Jerome <sol.jerome@gmail.com>
Tue, 17 Aug 2010 17:38:19 -0500
branchstable
changeset 12051 ff5cec76b1c5
parent 9041 6e5e548452de
permissions -rwxr-xr-x
util: avoid using hashlib on Python < 2.5 (issue2278) The following patch allows the use of python2.4 with a standalone hashlib rather than assuming that python2.5 is in use when hashlib is imported successfully.

#!/bin/sh

"$TESTDIR/hghave" gpg || exit 80

cat <<EOF >> $HGRCPATH
[extensions]
gpg=

[gpg]
cmd=gpg --no-permission-warning --no-secmem-warning --homedir $TESTDIR/gpg
EOF

hg init r
cd r
echo foo > foo
hg ci -Amfoo

echo '% no signatures'
hg sigs

echo '% hg sign 0'
hg sign 0

echo '% hg sigs'
hg sigs

echo '% hg sigcheck 0'
hg sigcheck 0