summaryrefslogtreecommitdiff
path: root/test/cider-locals-tests.el
diff options
context:
space:
mode:
authorArtur Malabarba <bruce.connor.am@gmail.com>2015-11-03 16:51:10 +0000
committerArtur Malabarba <bruce.connor.am@gmail.com>2015-11-04 09:47:31 +0000
commit366b6a4c7c8fd6fda198e723c254fa0d74b96b0d (patch)
treeeae0a77af108caaa9a687b2d44caa70be78b5dbe /test/cider-locals-tests.el
parente193c7aa8896b1598d3063d4423c61821fafcd60 (diff)
[Fix #1324] Don't font-lock local variables
Diffstat (limited to 'test/cider-locals-tests.el')
-rw-r--r--test/cider-locals-tests.el12
1 files changed, 12 insertions, 0 deletions
diff --git a/test/cider-locals-tests.el b/test/cider-locals-tests.el
index a9a12272..9706dc51 100644
--- a/test/cider-locals-tests.el
+++ b/test/cider-locals-tests.el
@@ -93,5 +93,17 @@
("a" "b" "the-ns")
(cider--read-locals-from-arglist)))
+(ert-deftest cider--test-unless-local ()
+ (with-temp-buffer
+ (clojure-mode)
+ (insert (propertize "the-ns inc lalala" 'cider-locals '("inc" "x")))
+ (goto-char (point-min))
+ (search-forward-regexp "\\(\\sw\\|\\s_\\)+" nil 'noerror)
+ (should (cider--unless-local-match t))
+ (search-forward-regexp "\\(\\sw\\|\\s_\\)+" nil 'noerror)
+ (should-not (cider--unless-local-match t))
+ (search-forward-regexp "\\(\\sw\\|\\s_\\)+" nil 'noerror)
+ (should (cider--unless-local-match t))))
+
(provide 'cider-locals-tests)
;;; cider-locals-tests.el ends here