mirror of
https://git.savannah.gnu.org/git/emacs.git
synced 2025-01-26 19:18:50 +00:00
* test/lisp/emacs-lisp/package-tests.el: Improve signature tests
(package-test-signed): Don't rely on return value of 'package-install'. Make sure 'package-install' does indeed install the package.
This commit is contained in:
parent
dad1aeb307
commit
9793a46168
@ -484,14 +484,16 @@ Must called from within a `tar-mode' buffer."
|
||||
(package-import-keyring keyring)
|
||||
(package-refresh-contents)
|
||||
(let ((package-check-signature 'allow-unsigned))
|
||||
(should (package-install 'signed-good))
|
||||
(should (progn (package-install 'signed-good) 'noerror))
|
||||
(should-error (package-install 'signed-bad)))
|
||||
(package-delete (car (alist-get 'signed-good package-alist)))
|
||||
(let ((package-check-signature t))
|
||||
(should (package-install 'signed-good))
|
||||
(should (progn (package-install 'signed-good) 'noerror))
|
||||
(should-error (package-install 'signed-bad)))
|
||||
(package-delete (car (alist-get 'signed-good package-alist)))
|
||||
(let ((package-check-signature nil))
|
||||
(should (package-install 'signed-good))
|
||||
(should (package-install 'signed-bad)))
|
||||
(should (progn (package-install 'signed-good) 'noerror))
|
||||
(should (progn (package-install 'signed-bad) 'noerror)))
|
||||
;; Check if the installed package status is updated.
|
||||
(let ((buf (package-list-packages)))
|
||||
(package-menu-refresh)
|
||||
|
Loading…
Reference in New Issue
Block a user