diff options
author | Werner Koch <wk@gnupg.org> | 2010-10-14 10:32:55 +0200 |
---|---|---|
committer | Werner Koch <wk@gnupg.org> | 2010-10-14 10:32:55 +0200 |
commit | fd19a84c805099c4f672a3d0968c87d305c647a9 (patch) | |
tree | e90ffb4e55c30b71518eff3ca26aab594056c755 /tests | |
parent | More agent support for gpg. (diff) | |
download | gnupg2-fd19a84c805099c4f672a3d0968c87d305c647a9.tar.xz gnupg2-fd19a84c805099c4f672a3d0968c87d305c647a9.zip |
Some tweaks to the agent startup.
Diffstat (limited to 'tests')
-rw-r--r-- | tests/Makefile.am | 2 | ||||
-rw-r--r-- | tests/openpgp/Makefile.am | 6 | ||||
-rwxr-xr-x | tests/openpgp/defs.inc | 25 | ||||
-rw-r--r-- | tests/openpgp/gpg-agent.conf.tmpl | 3 |
4 files changed, 18 insertions, 18 deletions
diff --git a/tests/Makefile.am b/tests/Makefile.am index c4693c01d..e9f3df232 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -46,7 +46,7 @@ EXTRA_DIST = runtest inittests $(testscripts) \ samplekeys/cert_g10code_test1.pem \ samplekeys/cert_g10code_theo1.pem -# We used to run $(testscripts) here but tehse asschk scripts ares not +# We used to run $(testscripts) here but these asschk scripts ares not # completely reliable in all enviromnets and thus we better disable # them. The tests are anyway way to minimal. We will eventually # write new tests based on gpg-connect-agent which has a full fledged diff --git a/tests/openpgp/Makefile.am b/tests/openpgp/Makefile.am index 0900e8f3e..ba1a65529 100644 --- a/tests/openpgp/Makefile.am +++ b/tests/openpgp/Makefile.am @@ -16,15 +16,14 @@ # along with this program; if not, see <http://www.gnu.org/licenses/>. # Process this file with automake to create Makefile.in -GPG_IMPORT = ../../g10/gpg2 --homedir . \ +GPG_IMPORT = ../../g10/gpg2 --homedir $(abs_builddir) \ --quiet --yes --no-permission-warning --import # Programs required before we can run these tests. required_pgms = ../../g10/gpg2 ../../agent/gpg-agent \ ../../tools/gpg-connect-agent -TESTS_ENVIRONMENT = GNUPGHOME=$(abs_builddir) GPG_AGENT_INFO= LC_ALL=C \ - ../../agent/gpg-agent --quiet --daemon sh +TESTS_ENVIRONMENT = GNUPGHOME=$(abs_builddir) GPG_AGENT_INFO= LC_ALL=C TESTS = version.test mds.test \ decrypt.test decrypt-dsa.test \ @@ -68,7 +67,6 @@ distclean-local: prepared.stamp: ./pubring.gpg ./secring.gpg ./plain-1 ./plain-2 ./plain-3 \ ./pubring.pkr ./secring.skr ./gpg_dearmor $(DATA_FILES) $(GPG_IMPORT) $(srcdir)/pubdemo.asc - cat $(srcdir)/gpg-agent.conf.tmpl > gpg-agent.conf echo timestamp >./prepared.stamp # We need to depend on a couple of programs so that the tests don't diff --git a/tests/openpgp/defs.inc b/tests/openpgp/defs.inc index 3e46ebd61..1158fb0cd 100755 --- a/tests/openpgp/defs.inc +++ b/tests/openpgp/defs.inc @@ -1,6 +1,6 @@ # Definitions for the OpenPGP test scripts -*- sh -*- # Copyright 1998,1999,2000,2001,2002,2003,2004,2005,2006, -# 2007 Free Software Foundation, Inc. +# 2007, 2010 Free Software Foundation, Inc. # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without # modifications, as long as this notice is preserved. This file is @@ -161,26 +161,27 @@ pgmname=`basename $0` [ -z "$srcdir" ] && fatal "not called from make" -# Make sure we have a valid option files even with VPATH builds. -for f in gpg.conf ; do - if [ -f ./$f ]; then - : - elif [ -f $srcdir/$f.tmpl ]; then - cat $srcdir/$f.tmpl >$f - fi -done - # Always work in the current directory. We set GNUPGHOME only if it # has not been set already. Usually it is set through the Makefile's # TESTS_ENVIRONMENT macro. if [ -z "$GNUPGHOME" ]; then - GNUPGHOME=`pwd` + GNUPGHOME=`/bin/pwd` export GNUPGHOME -elif [ "$GNUPGHOME" != `pwd` ]; then +elif [ "$GNUPGHOME" != `/bin/pwd` ]; then echo "$pgmname: GNUPGHOME not set to the cwd" $* >&2 exit 1 fi +# Make sure we have a valid option files even with VPATH builds. +for f in gpg.conf gpg-agent.conf ; do + if [ -f ./$f ]; then + : + elif [ -f $srcdir/$f.tmpl ]; then + cat $srcdir/$f.tmpl >$f + fi +done + +# (--no-permission-warning makes only sense on the commandline) GPG="../../g10/gpg2 --no-permission-warning " echo "Test: $pgmname" > ${pgmname}.log diff --git a/tests/openpgp/gpg-agent.conf.tmpl b/tests/openpgp/gpg-agent.conf.tmpl index 18e15206b..3833e0a8f 100644 --- a/tests/openpgp/gpg-agent.conf.tmpl +++ b/tests/openpgp/gpg-agent.conf.tmpl @@ -1,2 +1,3 @@ -no-use-standard-socket +use-standard-socket + |