summaryrefslogtreecommitdiff
path: root/test/lisp/epg-tests.el
diff options
context:
space:
mode:
Diffstat (limited to 'test/lisp/epg-tests.el')
-rw-r--r--test/lisp/epg-tests.el11
1 files changed, 10 insertions, 1 deletions
diff --git a/test/lisp/epg-tests.el b/test/lisp/epg-tests.el
index 3659a922fe3..ed9da90c029 100644
--- a/test/lisp/epg-tests.el
+++ b/test/lisp/epg-tests.el
@@ -111,14 +111,23 @@ jA0ECQMCdW8+qtS9Tin/0jUBO1/9Oz69BWPmtFKEeBM62WpFP4o1+bNzdxogdyeg
-----END PGP MESSAGE-----
")))))
+(defun epg--gnupg-version-is-not-buggy ()
+ ;; We need to skip some versions of GnuPG, as they make tests hang.
+ ;; See Bug#63256 and https://dev.gnupg.org/T6481 as well as PROBLEMS.
+ ;; Known bad versions for now are 2.4.1--2.4.3.
+ (not (string-match (rx bos "gpg (GnuPG) 2.4." (+ digit))
+ (shell-command-to-string "gpg --version"))))
+
(ert-deftest epg-roundtrip-1 ()
- :expected-result (if (getenv "EMACS_HYDRA_CI") :failed :passed) ; fixme
+ :expected-result (if (getenv "EMACS_HYDRA_CI") :failed :passed) ; fixme
+ (skip-unless (epg--gnupg-version-is-not-buggy))
(with-epg-tests (:require-passphrase t)
(let ((cipher (epg-encrypt-string epg-tests-context "symmetric" nil)))
(should (equal "symmetric"
(epg-decrypt-string epg-tests-context cipher))))))
(ert-deftest epg-roundtrip-2 ()
+ (skip-unless (epg--gnupg-version-is-not-buggy))
(with-epg-tests (:require-passphrase t
:require-public-key t
:require-secret-key t)