Compare commits

...

2 Commits

Author SHA1 Message Date
Tristan B. Velloza Kildaire 838ddbb9db Tree (unittests)
- Added missing assertions
2024-04-26 15:36:54 +02:00
Tristan B. Velloza Kildaire e44caf3643 VisitationTree (unittests)
- Added missing assertions
2024-04-26 15:35:29 +02:00
1 changed files with 10 additions and 1 deletions

View File

@ -747,6 +747,11 @@ unittest
string[] result = treeOfStrings.dfs(strat, touch);
writeln("dfs: ", result);
assert(result[0] == "1");
assert(result[1] == "2");
assert(result[2] == "3");
assert(result[3] == "Top");
}
public class VisitationTree(T) : Tree!(T)
@ -797,6 +802,10 @@ unittest
root.appendNode(thing);
thing.appendNode(root);
writeln(root.linearize());
string[] linearized = root.linearize();
writeln(linearized);
assert(linearized[0] == "subtree");
assert(linearized[1] == "root");
}