These test both graph shape consistency and single value outputs. Eventually we want to make the graph shape tests more precise, and also verify specific outputs how it used to be. For now, this is okay. Co-authored-by: Samuel Gélineau <gelisam@gmail.com>
17 lines
288 B
Plaintext
17 lines
288 B
Plaintext
-- main.mcl --
|
|
import "iter"
|
|
|
|
$in = ["a", "bb", "ccc", "dddd", "eeeee",]
|
|
|
|
# the inline lambda format is more readable with the func as the second arg
|
|
$out = iter.map($in, func($x) {
|
|
len($x)
|
|
|
|
})
|
|
|
|
$t = template("out: {{ . }}", $out)
|
|
|
|
test $t {}
|
|
-- OUTPUT --
|
|
Vertex: test[out: [1 2 3 4 5]]
|