upTreeTraversal finished, fixed a bug in fixture parser where every node had parent set to 0

unfinished test that checks agains that error
This commit is contained in:
2026-07-20 18:15:50 +02:00
parent e89cec47d9
commit 46f9e05d63
4 changed files with 29 additions and 3 deletions
+3 -1
View File
@@ -50,7 +50,9 @@ describe("upTraverseTree", () => {
test("successfully traverses up the tree", () => {
const result = upTraverseTree(fsTwo, 7);
console.log(result);
//expect(result, `Checking the result ${result} to be [0, 1, 2, 3]`).toEqual([0, 2, 3, 1]);
expect(result, `Checking the result ${result} to be [7, 6, 5, 4, 3, 2, 1, 0]`).toEqual([
7, 6, 5, 4, 3, 2, 1, 0,
]);
});
test("returns empty array for a non existent inode", () => {