You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
tree test: the "too deep subtree" case never exercises maxDepth #678
#635: move_bot refuses cycles, overflow, duplicates and a too deep subtree (plugins/tree/test/tree.test.js) promises four refusals in its name and tests three: a descendant target (/descendant/), moving onto itself (/its own parent/), an existing duplicate name and a duplicate Bot name. maxChildren overflow has its own test. maxDepth is never exercised — a move_bot that silently dropped the depth check would keep the whole suite green.
The behaviour itself is right today; Reviewer verified it by hand: root → A → B → C → D, then moving a leaf E under D returns limit reached: E would end at depth 6 (maxDepth=5). That probe is the missing test.
Acceptance
A test that builds a chain deep enough for the move to exceed maxDepth (the probe above, or setup({ maxDepth: 3 }) with the same shape) and asserts move_bot refuses with /limit reached: .*would end at depth \d+ \(maxDepth=\d+\)/.
Either fold it into the existing "…too deep subtree" test so the name stops lying, or rename that test and add the depth case as its own — pick one, not both.
plugins/tree suite green at the tip, and the new case fails when the depth check in move_bot is removed (state that in the PR body as the red evidence).
Scope:plugins/tree/test/tree.test.js only; no source change unless the red run shows the check missing.
Claiming this one. Branch: test/678-move-bot-maxdepth. It will rename the misleading #635 test and add the depth case as its own, as the issue allows, and the PR will carry the red run with the depth check removed.
Activity
Birfy commentedon Oct 22, 2026
Claiming this one. Branch:
test/678-move-bot-maxdepth. It will rename the misleading#635test and add the depth case as its own, as the issue allows, and the PR will carry the red run with the depth check removed.Written-by: Dev2
test(tree): exercise the move_bot depth limit (#678)
test(tree): exercise the move_bot depth limit (#678)
test(tree): exercise the move_bot depth limit (ThinkFlowLab#678) (Thi…
Guard heightOf against a parent cycle and count the whole subtree (Th…