Adding tests for String.join and String.join-with

Issue #94
This commit is contained in:
Chris Hall 2018-05-19 13:20:56 +10:00
parent 513de1f738
commit 35c8dd9bfa

View File

@ -197,6 +197,26 @@
&(split-by "erikmsvedlhejxfoo" &[\m \l \x])
"split-by works correctly"
)
(assert-equal test
"hello world"
&(join &[@"hello" @" " @"world"])
"join works correctly"
)
(assert-equal test
"hello world"
&(join-with "" &[@"hello" @" " @"world"])
"join-with works correctly I"
)
(assert-equal test
"hello world"
&(join-with " " &[@"hello" @"world"])
"join-with works correctly II"
)
(assert-equal test
"hello aaaa there aaaa world"
&(join-with " aaaa " &[@"hello" @"there" @"world"])
"join-with works correctly III"
)
(print-test-results test)
)
)