diff options
author | Werner Koch <[email protected]> | 2022-11-02 16:03:05 +0000 |
---|---|---|
committer | Werner Koch <[email protected]> | 2022-11-02 16:03:05 +0000 |
commit | 9b24d8ab5018c20dc6c917b5a89b3b1fcda3e6f9 (patch) | |
tree | 842569e5c197bf3221d11e07b0837af7437d0fac /tests/gpgscm | |
parent | agent: Avoid blanks in the ssh key's comment. (diff) | |
download | gnupg-9b24d8ab5018c20dc6c917b5a89b3b1fcda3e6f9.tar.gz gnupg-9b24d8ab5018c20dc6c917b5a89b3b1fcda3e6f9.zip |
tests: Add tr:assert-same function.
* tests/gpgscm/tests.scm (tr:assert-same-string): New.
* tests/openpgp/shell.scm: Option to drop into a REPL.
Diffstat (limited to 'tests/gpgscm')
-rw-r--r-- | tests/gpgscm/tests.scm | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/gpgscm/tests.scm b/tests/gpgscm/tests.scm index eb278e301..cebe419f8 100644 --- a/tests/gpgscm/tests.scm +++ b/tests/gpgscm/tests.scm @@ -493,6 +493,12 @@ (fail "mismatch")) (list tmpfiles source #f))) +(define (tr:assert-same reference) + (lambda (tmpfiles source) + (if (not (string=? (call-with-input-file source read-all) reference)) + (fail "mismatch")) + (list tmpfiles source #f))) + (define (tr:call-with-content function . args) (lambda (tmpfiles source) (catch (list tmpfiles source *error*) |