diff options
Diffstat (limited to 'test/lisp/emacs-lisp')
-rw-r--r-- | test/lisp/emacs-lisp/package-resources/with-nil-entry/archive-contents | 8 | ||||
-rw-r--r-- | test/lisp/emacs-lisp/package-tests.el | 10 |
2 files changed, 18 insertions, 0 deletions
diff --git a/test/lisp/emacs-lisp/package-resources/with-nil-entry/archive-contents b/test/lisp/emacs-lisp/package-resources/with-nil-entry/archive-contents new file mode 100644 index 00000000000..03e6aa7f7c6 --- /dev/null +++ b/test/lisp/emacs-lisp/package-resources/with-nil-entry/archive-contents @@ -0,0 +1,8 @@ +(1 + (foo . + [(1 0) + nil "foo package" single]) + nil + (bar . + [(1 0) + nil "bar package" single])) diff --git a/test/lisp/emacs-lisp/package-tests.el b/test/lisp/emacs-lisp/package-tests.el index 8670e6f3fac..828c456842a 100644 --- a/test/lisp/emacs-lisp/package-tests.el +++ b/test/lisp/emacs-lisp/package-tests.el @@ -452,6 +452,16 @@ Must called from within a `tar-mode' buffer." (search-forward-regexp "^ +simple-single" nil t)))) (if (process-live-p process) (kill-process process))))) +(ert-deftest package-test-update-archives/ignore-nil-entry () + "Ignore any packages that are nil. Test for Bug#28502." + (with-package-test () + (let* ((with-nil-entry (expand-file-name "package-resources/with-nil-entry" + package-test-file-dir)) + (package-archives `(("with-nil-entry" . ,with-nil-entry)))) + (package-initialize) + (package-refresh-contents) + (should (equal (length package-archive-contents) 2))))) + (ert-deftest package-test-describe-package () "Test displaying help for a package." |