[PATCH STABLE] test-gpg: make sure gpg does not modify the trustdb.gpg file

1 view
Skip to first unread message

Greg Ward

unread,
Mar 21, 2012, 10:20:13 PM3/21/12
to mercuri...@selenic.com
# HG changeset patch
# User Greg Ward <gr...@gerg.ca>
# Date 1332382572 14400
# Branch stable
# Node ID b92f8ff8c71e96f62890aac263d3d7c06484b49b
# Parent 2338ab19b23690e74e1ba3936667399dfeb9490c
test-gpg: make sure gpg does not modify the trustdb.gpg file

Tests really should not modify files in the Mercurial working dir
where they ran from! I suspect that trustdb.gpg is now old enough that
GPG thinks it should update it automatically. Suppress that feature
with --no-auto-check-trustdb.

diff --git a/tests/test-gpg.t b/tests/test-gpg.t
--- a/tests/test-gpg.t
+++ b/tests/test-gpg.t
@@ -6,7 +6,7 @@
> gpg=
>
> [gpg]
- > cmd=gpg --no-permission-warning --no-secmem-warning --homedir $TESTDIR/gpg
+ > cmd=gpg --no-permission-warning --no-secmem-warning --no-auto-check-trustdb --homedir $TESTDIR/gpg
> EOF
$ hg init r
$ cd r
@@ -25,3 +25,7 @@
$ hg sigcheck 0
e63c23eaa88a is signed by:
hgtest
+
+verify that this test has not modified the trustdb.gpg file back in
+the main hg working dir
+ $ hg --cwd $TESTDIR status gpg
_______________________________________________
Mercurial-devel mailing list
Mercuri...@selenic.com
http://selenic.com/mailman/listinfo/mercurial-devel

Reply all
Reply to author
Forward
0 new messages