tests: Use gpgconf to set the ssh socket envvar.
authorWerner Koch <wk@gnupg.org>
Thu, 4 Aug 2016 11:04:28 +0000 (13:04 +0200)
committerWerner Koch <wk@gnupg.org>
Thu, 4 Aug 2016 11:04:28 +0000 (13:04 +0200)
* tests/openpgp/ssh.scm ("SSH_AUTH_SOCK"): Use gpgconf.

Signed-off-by: Werner Koch <wk@gnupg.org>
tests/openpgp/ssh.scm

index fe0b115..dfa1f52 100755 (executable)
@@ -23,7 +23,9 @@
 (if (string=? "" GNUPGHOME)
     (error "GNUPGHOME not set"))
 
-(setenv "SSH_AUTH_SOCK" (path-join GNUPGHOME "S.gpg-agent.ssh") #t)
+(setenv "SSH_AUTH_SOCK"
+        (call-check `(,(tool 'gpgconf) --null --list-dirs agent-ssh-socket))
+        #t)
 
 (define SSH-ADD #f)
 (catch (skip "ssh-add not found")