summaryrefslogtreecommitdiffstats
path: root/tests/gpgme
diff options
context:
space:
mode:
authorJustus Winter <justus@g10code.com>2017-04-20 17:35:15 +0200
committerJustus Winter <justus@g10code.com>2017-04-24 15:59:49 +0200
commit06a177ceea529269a7404740c60416bd6a4567b1 (patch)
treefd7286cdb8fbfdca50b94953f50947025fa0c915 /tests/gpgme
parentgpgscm: Fix test. (diff)
downloadgnupg2-06a177ceea529269a7404740c60416bd6a4567b1.tar.xz
gnupg2-06a177ceea529269a7404740c60416bd6a4567b1.zip
tests: Deduplicate and simplify code.
* tests/gpgme/gpgme-defs.scm (create-file): Move... * tests/gpgsm/gpgsm-defs.scm (create-file): ... likewise... * tests/openpgp/defs.scm (create-file): Here. (create-gpghome): Use 'create-file'. * tests/openpgp/gpg-agent.conf.tmpl: Delete file. * tests/openpgp/gpg.conf.tmpl: Likewise. Signed-off-by: Justus Winter <justus@g10code.com>
Diffstat (limited to 'tests/gpgme')
-rw-r--r--tests/gpgme/gpgme-defs.scm5
1 files changed, 0 insertions, 5 deletions
diff --git a/tests/gpgme/gpgme-defs.scm b/tests/gpgme/gpgme-defs.scm
index 1e215b1e3..690d097fd 100644
--- a/tests/gpgme/gpgme-defs.scm
+++ b/tests/gpgme/gpgme-defs.scm
@@ -45,11 +45,6 @@
;; The tests expect the pinentry to return the passphrase "abc".
(setenv "PINENTRY_USER_DATA" "abc" #t)
-(define (create-file name . lines)
- (letfd ((fd (open name (logior O_WRONLY O_CREAT O_BINARY) #o600)))
- (let ((port (fdopen fd "wb")))
- (for-each (lambda (line) (display line port) (newline port)) lines))))
-
(define (create-gpgmehome . path)
;; Support for various environments.
(define mode