]> code.delx.au - gnu-emacs-elpa/commitdiff
Added test case to ensure keywords are sorted.
authorNikolaj Schumacher <git@nschum.de>
Thu, 7 May 2009 12:09:24 +0000 (14:09 +0200)
committerNikolaj Schumacher <git@nschum.de>
Thu, 7 May 2009 13:13:36 +0000 (15:13 +0200)
tests.elk [new file with mode: 0644]

diff --git a/tests.elk b/tests.elk
new file mode 100644 (file)
index 0000000..0d9288b
--- /dev/null
+++ b/tests.elk
@@ -0,0 +1,11 @@
+(require 'elk-test)
+
+(deftest "Sorted keywords"
+  (require 'company-keywords)
+  (dolist (pair company-keywords-alist)
+    (when (consp (cdr pair))
+      (let ((prev (cadr pair)))
+        (dolist (next (cddr pair))
+          (assert-not-equal prev next)
+          (assert-string< prev next)
+          (setq prev next))))))