aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/tcolumnize.nim11
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/tcolumnize.nim b/tests/tcolumnize.nim
new file mode 100644
index 0000000..950b040
--- /dev/null
+++ b/tests/tcolumnize.nim
@@ -0,0 +1,11 @@
+import soon/columnize
+import std/[unittest, strutils]
+
+test "Testing columize":
+ var table = newSeq[seq[string]]()
+ let line1 = @["Jan 1", "(OVERDUE)", "Do the thing"]
+ let line2 = @["Feb 22", "(Due in 24 days)", "Do that other thing"]
+ table.add(line1)
+ table.add(line2)
+ for line in columnize(table):
+ echo line.join(" ")