diff options
author | Noam Postavsky <npostavs@gmail.com> | 2018-07-14 08:58:26 -0400 |
---|---|---|
committer | Noam Postavsky <npostavs@gmail.com> | 2018-07-14 09:01:39 -0400 |
commit | 5936f6cdac09aa2f420f7f3756cf77629af99344 (patch) | |
tree | 8e9dfd06187da1016880d5aa88dbab9466f5e364 /test/lisp/epg-tests.el | |
parent | 9f25231f354a973d5331b62717ec46e0cbcbbc6e (diff) | |
download | emacs-5936f6cdac09aa2f420f7f3756cf77629af99344.tar.gz emacs-5936f6cdac09aa2f420f7f3756cf77629af99344.tar.bz2 emacs-5936f6cdac09aa2f420f7f3756cf77629af99344.zip |
; Trace epg-tests gpg config finding (Bug#23561)
Diffstat (limited to 'test/lisp/epg-tests.el')
-rw-r--r-- | test/lisp/epg-tests.el | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/test/lisp/epg-tests.el b/test/lisp/epg-tests.el index 7efe04bfc00..361ba8fc0c2 100644 --- a/test/lisp/epg-tests.el +++ b/test/lisp/epg-tests.el @@ -23,6 +23,7 @@ (require 'ert) (require 'epg) +(require 'trace) (defvar epg-tests-context nil) @@ -42,7 +43,19 @@ prog-alist)) (defun epg-tests-find-usable-gpg-configuration (&optional _require-passphrase) - (epg-find-configuration 'OpenPGP 'no-cache epg-tests--config-program-alist)) + ;; Tracing for Bug#23561, but only do it once per run. + (if (get-buffer "*trace-output*") + (epg-find-configuration 'OpenPGP 'no-cache epg-tests--config-program-alist) + (dolist (fun '(epg-find-configuration + executable-find + epg-check-configuration + epg-config--make-gpg-configuration)) + (trace-function-background fun)) + (prog1 (unwind-protect + (epg-find-configuration 'OpenPGP 'no-cache epg-tests--config-program-alist) + (untrace-all)) + (princ (with-current-buffer "*trace-output*" (buffer-string)) + #'external-debugging-output)))) (defun epg-tests-passphrase-callback (_c _k _d) ;; Need to create a copy here, since the string will be wiped out |