diff options
| author | 2025-01-27 07:08:13 -0500 | |
|---|---|---|
| committer | 2025-01-27 07:08:13 -0500 | |
| commit | 18e51e47f121b08dfeb9adc5584f41e11e0d3b09 (patch) | |
| tree | 916d25ae1c0a2d8e89689cc6423cc6be299ea898 /tests | |
| parent | update documentation (diff) | |
basic tests for unordered list items
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/run.scm | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/tests/run.scm b/tests/run.scm index 87cbfa3..f140892 100644 --- a/tests/run.scm +++ b/tests/run.scm @@ -334,3 +334,29 @@ (test-equal "text" "quoted code\n" text)))) + +;;; TODO: check number of children of each node. + +(test-group "unordered lists" + (test-group "one element" + (let ((lst (chain (parse->document "* hello, world") + (node-children _) + (list-queue-list _) + (list-ref _ 0)))) + (test-assert "unordered-list-item?" (unordered-list-item? lst)) + (let ((str (chain (node-children lst) + (list-queue-list _) + (list-ref _ 0) + (xstring->string _)))) + (test-equal "text" "hello, world\n" str)))) + (test-group "one element continued" + (let ((str (chain (parse->document "* hello,") + (parse->document " world" _) + (node-children _) + (list-queue-list _) + (list-ref _ 0) + (node-children _) + (list-queue-list _) + (list-ref _ 0) + (xstring->string _)))) + (test-equal "text" "hello,\nworld\n" str)))) |
