diff options
author | Justus Winter <justus@g10code.com> | 2017-05-04 14:24:50 +0200 |
---|---|---|
committer | Justus Winter <justus@g10code.com> | 2017-05-04 14:25:38 +0200 |
commit | eab0138e3179f247180a639a91570e5ee2c6ad0e (patch) | |
tree | c02dc1d11af5b45ab9e406dc8933d9e073927913 | |
parent | speedo,w32: Fix silent user mode installation (diff) | |
download | gnupg2-eab0138e3179f247180a639a91570e5ee2c6ad0e.tar.xz gnupg2-eab0138e3179f247180a639a91570e5ee2c6ad0e.zip |
tests: Add function to dump packets.
* tests/openpgp/defs.scm (gpg-dump-packets): New function.
Signed-off-by: Justus Winter <justus@g10code.com>
-rw-r--r-- | tests/openpgp/defs.scm | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/openpgp/defs.scm b/tests/openpgp/defs.scm index 9e681bf92..8d7caed04 100644 --- a/tests/openpgp/defs.scm +++ b/tests/openpgp/defs.scm @@ -299,6 +299,12 @@ (pipe:spawn `(,@GPG --dearmor)) (pipe:write-to sink-name (logior O_WRONLY O_CREAT O_BINARY) #o600))) +(define (gpg-dump-packets source-name sink-name) + (pipe:do + (pipe:open source-name (logior O_RDONLY O_BINARY)) + (pipe:spawn `(,@GPG --list-packets)) + (pipe:write-to sink-name (logior O_WRONLY O_CREAT O_BINARY) #o600))) + ;; ;; Support for test environment creation and teardown. ;; |