aboutsummaryrefslogtreecommitdiffstats
path: root/test/lisp
diff options
context:
space:
mode:
Diffstat (limited to 'test/lisp')
-rw-r--r--test/lisp/imenu-tests.el10
1 files changed, 10 insertions, 0 deletions
diff --git a/test/lisp/imenu-tests.el b/test/lisp/imenu-tests.el
index 480368fcbb6..93090947139 100644
--- a/test/lisp/imenu-tests.el
+++ b/test/lisp/imenu-tests.el
@@ -83,6 +83,16 @@ function ABC_D()
83} 83}
84" '("a" "b" "c" "ABC_D")) 84" '("a" "b" "c" "ABC_D"))
85 85
86(ert-deftest imenu--sort-by-position-pairs ()
87 (should (imenu--sort-by-position '("a" . 2) '("a" . 3)))
88 (should-not (imenu--sort-by-position '("a" . 3) '("a" . 2))))
89
90;; Regression test for bug#26457: 25.2; Cannot pass a function to
91;; imenu-generic-expression
92(ert-deftest imenu--sort-by-position-list ()
93 (should (imenu--sort-by-position '("a" 2 nil) '("a" 3 nil)))
94 (should-not (imenu--sort-by-position '("a" 3 nil) '("a" 2 nil))))
95
86(provide 'imenu-tests) 96(provide 'imenu-tests)
87 97
88;;; imenu-tests.el ends here 98;;; imenu-tests.el ends here