about summary refs log tree commit diff
path: root/users/wpcarro/emacs/pkgs/list/tests.el
diff options
context:
space:
mode:
Diffstat (limited to 'users/wpcarro/emacs/pkgs/list/tests.el')
-rw-r--r--users/wpcarro/emacs/pkgs/list/tests.el10
1 files changed, 10 insertions, 0 deletions
diff --git a/users/wpcarro/emacs/pkgs/list/tests.el b/users/wpcarro/emacs/pkgs/list/tests.el
index abba6b59d62f..a6096a1d6e92 100644
--- a/users/wpcarro/emacs/pkgs/list/tests.el
+++ b/users/wpcarro/emacs/pkgs/list/tests.el
@@ -42,3 +42,13 @@
 (ert-deftest list-join ()
   (should (equal "foo-bar-baz"
                  (list-join "-" '("foo" "bar" "baz")))))
+
+(ert-deftest list-chunk ()
+  (should (equal '((1 2 3 4 5 6))
+                 (list-chunk 7 '(1 2 3 4 5 6))))
+  (should (equal '((1) (2) (3) (4) (5) (6))
+                 (list-chunk 1 '(1 2 3 4 5 6))))
+  (should (equal '((1 2 3) (4 5 6))
+                 (list-chunk 3 '(1 2 3 4 5 6))))
+  (should (equal '((1 2) (3 4) (5 6))
+                 (list-chunk 2 '(1 2 3 4 5 6)))))