Module talk:Iterators/testcases
All tests passed.
Text | Expected | Actual | |
---|---|---|---|
chaining iteration on {1, 2, 3} then {4, 5, 6} | {1,2,3,4,5,6} | {1,2,3,4,5,6} | |
chaining iteration on {1, 2, 3} then {4, 5, 6} (object notation) | {1,2,3,4,5,6} | {1,2,3,4,5,6} |
Text | Expected | Actual | |
---|---|---|---|
filter on pair vals on {1, 2, 3} | {2} | {2} | |
filter on pair vals on {1, 2, 3} (object notation) | {2} | {2} |
Text | Expected | Actual | |
---|---|---|---|
test flattening {{"plop", "plop"}, {}, {"plop"}} | {"plop","plop","plop"} | {"plop","plop","plop"} | |
test flattening {{"plop", "plop"}, {}, {"plop"}} (object notation) | {"plop","plop","plop"} | {"plop","plop","plop"} |
Text | Expected | Actual | |
---|---|---|---|
Test of fold on all values of a table, by an insertion on an initially empty table. Supposed to be an id op | {1,2,3} | {1,2,3} | |
same as above in object notation style | {1,2,3} | {1,2,3} | |
Test of the « totable » function that puts all values of iteration on a table. basically the same of the preceding. | {1,2,3} | {1,2,3} |
Text | Expected | Actual | |
---|---|---|---|
range generator (5 to 8) | {5,6,7} | {5,6,7} | |
range generator (5 to 8) (object notation | {5,6,7} | {5,6,7} | |
range generator (5 to 8) - step 2 (object notation | {5,7} | {5,7} | |
range generator (8 to 5) - step -2 (object notation | {8,6} | {8,6} |
Text | Expected | Actual | |
---|---|---|---|
map, double {1, 2, 3} | {2,4,6} | {2,4,6} | |
map, double {1, 2, 3} (object notation) | {2,4,6} | {2,4,6} |
Text | Expected | Actual | |
---|---|---|---|
a map on the pairs of {a = 1 , b = 3} that selects keys | {"a",1} | {"a",1} | |
a map on the pairs of {a = 1 , b = 3} that selects keys | {"a","b"} | {"a","b"} |
All tests passed.
Text | Expected | Actual | |
---|---|---|---|
chaining iteration on {1, 2, 3} then {4, 5, 6} | {1,2,3,4,5,6} | {1,2,3,4,5,6} | |
chaining iteration on {1, 2, 3} then {4, 5, 6} (object notation) | {1,2,3,4,5,6} | {1,2,3,4,5,6} |
Text | Expected | Actual | |
---|---|---|---|
filter on pair vals on {1, 2, 3} | {2} | {2} | |
filter on pair vals on {1, 2, 3} (object notation) | {2} | {2} |
Text | Expected | Actual | |
---|---|---|---|
test flattening {{"plop", "plop"}, {}, {"plop"}} | {"plop","plop","plop"} | {"plop","plop","plop"} | |
test flattening {{"plop", "plop"}, {}, {"plop"}} (object notation) | {"plop","plop","plop"} | {"plop","plop","plop"} |
Text | Expected | Actual | |
---|---|---|---|
Test of fold on all values of a table, by an insertion on an initially empty table. Supposed to be an id op | {1,2,3} | {1,2,3} | |
same as above in object notation style | {1,2,3} | {1,2,3} | |
Test of the « totable » function that puts all values of iteration on a table. basically the same of the preceding. | {1,2,3} | {1,2,3} |
Text | Expected | Actual | |
---|---|---|---|
range generator (5 to 8) | {5,6,7} | {5,6,7} | |
range generator (5 to 8) (object notation | {5,6,7} | {5,6,7} | |
range generator (5 to 8) - step 2 (object notation | {5,7} | {5,7} | |
range generator (8 to 5) - step -2 (object notation | {8,6} | {8,6} |
Text | Expected | Actual | |
---|---|---|---|
map, double {1, 2, 3} | {2,4,6} | {2,4,6} | |
map, double {1, 2, 3} (object notation) | {2,4,6} | {2,4,6} |
Text | Expected | Actual | |
---|---|---|---|
a map on the pairs of {a = 1 , b = 3} that selects keys | {"a",1} | {"a",1} | |
a map on the pairs of {a = 1 , b = 3} that selects keys | {"a","b"} | {"a","b"} |
All tests passed.
Text | Expected | Actual | |
---|---|---|---|
chaining iteration on {1, 2, 3} then {4, 5, 6} | {1,2,3,4,5,6} | {1,2,3,4,5,6} | |
chaining iteration on {1, 2, 3} then {4, 5, 6} (object notation) | {1,2,3,4,5,6} | {1,2,3,4,5,6} |
Text | Expected | Actual | |
---|---|---|---|
filter on pair vals on {1, 2, 3} | {2} | {2} | |
filter on pair vals on {1, 2, 3} (object notation) | {2} | {2} |
Text | Expected | Actual | |
---|---|---|---|
test flattening {{"plop", "plop"}, {}, {"plop"}} | {"plop","plop","plop"} | {"plop","plop","plop"} | |
test flattening {{"plop", "plop"}, {}, {"plop"}} (object notation) | {"plop","plop","plop"} | {"plop","plop","plop"} |
Text | Expected | Actual | |
---|---|---|---|
Test of fold on all values of a table, by an insertion on an initially empty table. Supposed to be an id op | {1,2,3} | {1,2,3} | |
same as above in object notation style | {1,2,3} | {1,2,3} | |
Test of the « totable » function that puts all values of iteration on a table. basically the same of the preceding. | {1,2,3} | {1,2,3} |
Text | Expected | Actual | |
---|---|---|---|
range generator (5 to 8) | {5,6,7} | {5,6,7} | |
range generator (5 to 8) (object notation | {5,6,7} | {5,6,7} | |
range generator (5 to 8) - step 2 (object notation | {5,7} | {5,7} | |
range generator (8 to 5) - step -2 (object notation | {8,6} | {8,6} |
Text | Expected | Actual | |
---|---|---|---|
map, double {1, 2, 3} | {2,4,6} | {2,4,6} | |
map, double {1, 2, 3} (object notation) | {2,4,6} | {2,4,6} |
Text | Expected | Actual | |
---|---|---|---|
a map on the pairs of {a = 1 , b = 3} that selects keys | {"a",1} | {"a",1} | |
a map on the pairs of {a = 1 , b = 3} that selects keys | {"a","b"} | {"a","b"} |