rename examples/tests/{a,b,c,d,e,f} into examples/acceptance_tests/00{1,2,3,4,5,6}
Also added a little Makefile to run them all in one go.
This commit is contained in:
11
examples/acceptance_tests/002/lib/test.ak
Normal file
11
examples/acceptance_tests/002/lib/test.ak
Normal file
@@ -0,0 +1,11 @@
|
||||
pub fn repeat(x: a, n: Int) -> List<a> {
|
||||
if n <= 0 {
|
||||
[]
|
||||
} else {
|
||||
[x, ..repeat(x, n - 1)]
|
||||
}
|
||||
}
|
||||
|
||||
test repeat_1() {
|
||||
repeat("aiken", 2) == ["aiken", "aiken"]
|
||||
}
|
||||
Reference in New Issue
Block a user