summaryrefslogtreecommitdiff
path: root/test/lisp/use-package/use-package-tests.el
diff options
context:
space:
mode:
authorTroy Hinckley <t.macman@gmail.com>2021-05-17 18:33:28 -0600
committerTroy Hinckley <t.macman@gmail.com>2021-05-17 18:33:28 -0600
commitee292b80bebc2e7a4f3b32bd51363adbb28878d2 (patch)
tree50d25cf6f02ddacbd09b3c95edeb3b45cb27f44e /test/lisp/use-package/use-package-tests.el
parent24c50da3b272f571c320ef800a80c0bc0ce38e28 (diff)
downloademacs-ee292b80bebc2e7a4f3b32bd51363adbb28878d2.tar.gz
emacs-ee292b80bebc2e7a4f3b32bd51363adbb28878d2.tar.bz2
emacs-ee292b80bebc2e7a4f3b32bd51363adbb28878d2.zip
Fix tests and documentation for hook
Diffstat (limited to 'test/lisp/use-package/use-package-tests.el')
-rw-r--r--test/lisp/use-package/use-package-tests.el12
1 files changed, 7 insertions, 5 deletions
diff --git a/test/lisp/use-package/use-package-tests.el b/test/lisp/use-package/use-package-tests.el
index 3825aa36487..b8063a046f5 100644
--- a/test/lisp/use-package/use-package-tests.el
+++ b/test/lisp/use-package/use-package-tests.el
@@ -998,15 +998,17 @@
'foopkg :hook args)))
(should-error (norm nil))
(should (equal (norm '(bar))
+ '((bar . foopkg-mode))))
+ (should (equal (norm '((bar . foopkg)))
'((bar . foopkg))))
(should (equal (norm '((bar . baz)))
'((bar . baz))))
(should (equal (norm '(((bar baz) . quux)))
'(((bar baz) . quux))))
(should (equal (norm '(bar baz))
- '(((bar baz) . foopkg))))
+ '(((bar baz) . foopkg-mode))))
(should (equal (norm '((bar baz) (quux bow)))
- '(((bar baz) . foopkg) ((quux bow) . foopkg))))
+ '(((bar baz) . foopkg-mode) ((quux bow) . foopkg-mode))))
(should (equal (norm '((bar . baz) (quux . bow)))
'((bar . baz) (quux . bow))))
(should (equal (norm '(((bar1 bar2) . baz) ((quux1 quux2) . bow)))
@@ -1945,9 +1947,9 @@
(use-package nonexistent
:hook lisp-mode)
`(when (locate-library nonexistent)
- (unless (fboundp 'nonexistent)
- (autoload #'nonexistent "nonexistent" nil t))
- (add-hook 'lisp-mode-hook #'nonexistent)))))
+ (unless (fboundp 'nonexistent-mode)
+ (autoload #'nonexistent-mode "nonexistent" nil t))
+ (add-hook 'lisp-mode-hook #'nonexistent-mode)))))
(ert-deftest bind-key/:prefix-map ()
(match-expansion