Skip to content

Run bootstrap.sh's Whole Main Flow Against a Stub Download and Stub Tools - #2589

Merged
ptr727 merged 2 commits into
developfrom
feature/wsl-1767
Oct 8, 2026
Merged

ptr727 merged 2 commits into
developfrom
feature/wsl-1767

Conversation

@ptr727

@ptr727 ptr727 commented Oct 8, 2026

Copy link
Copy Markdown
Owner

Adds TestKeptTreeEndToEnd to tests/test_bootstrap.py: option 1 of #1767 for the bash loader. It runs the real host-setup/bootstrap.sh --host --yes --dir <scratch> with a scratch HOME, a stub curl on PATH serving a local tarball, and stub tools inside that tarball that log what the kept tree held when they ran and fail at a chosen stand-up step. A stub mv records whether the previous tree is still held aside at the moment the new one moves into place. No change to bootstrap.sh was needed.

Asserted from disk:

  • a failure at any step before the skills step leaves the previous tree loading, with no .new/.old/archive beside it, and the run stops at that step;
  • a first run failing early leaves no tree;
  • a success leaves only the new tree;
  • every tool before the skills step runs from skills-tree.new with the old tree intact, and the skills installer runs from the swapped-in skills-tree;
  • the old tree is still held at .old when the new one moves into place;
  • a failing installer leaves the new tree whole with no .old.

Verification on this host (WSL2 Debian): Ran 7 tests ... OK for the class, and the whole module OK (skipped=46). Local mutations, reverted and never committed: swapping in unconditionally during download failed 8 cases, deleting the old tree before staging failed 5, and replacing mv "$tree" "$retired" with rm -rf "$tree" failed the new held-aside case.

The PowerShell half is a windows lane item: #2587.

Closes on promotion: #1767

🤖 Generated with Claude Code

ptr727 and others added 2 commits October 8, 2026 14:29
…ools

TestKeptTreeEndToEnd runs bootstrap.sh --host with a stub curl serving a local tarball and stub tools failing at each stand-up step, and asserts the kept tree on disk: a failure before the skills step leaves the previous tree, a success leaves only the new one, and the previous tree is untouched until the skills step.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Copilot AI lite review requested due to automatic review settings October 8, 2026 21:33
@coderabbitai

coderabbitai Bot commented Oct 8, 2026

Copy link
Copy Markdown

Important

  • 🔍 Trigger review

This repository does not receive automatic reviews because it has fewer than 10 stars.

⚙️ Run configuration
  • Configuration used: Repository: ptr727/ProjectTemplate/.coderabbit.yaml
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 838b628f-ccaf-461e-a6bb-e0c4ac776416
  • Autopilot · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

The single-file test change covers the stated Linux scenarios, with no unresolved findings.

0 open findings

What changed in this PR

Adds whole-flow tests for the Linux bootstrap loader's kept-tree swap, addressing the bash portion of #1767. The PowerShell counterpart remains tracked in #2587.

Changes:

  • Runs bootstrap.sh --host with a local stub download and tools.
  • Checks tree state and cleanup after successful runs and failures at each stand-up step.
File Description
tests/​test_bootstrap.py Adds seven end-to-end tests for the Linux kept-tree flow.

🧠 Review effort: Lite


💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@codecov

codecov Bot commented Oct 8, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 58.85%. Comparing base (1ff98e3) to head (93364ab).

Additional details and impacted files
@@           Coverage Diff            @@
##           develop    #2589   +/-   ##
========================================
  Coverage    58.85%   58.85%           
========================================
  Files           16       16           
  Lines         8181     8181           
========================================
  Hits          4815     4815           
  Misses        3366     3366           
Flag Coverage Δ
python-3.13 58.85% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@ptr727
ptr727 merged commit db3ec1d into develop Oct 8, 2026
14 checks passed
@ptr727
ptr727 deleted the feature/wsl-1767 branch October 8, 2026 21:41
ptr727 added a commit that referenced this pull request Oct 8, 2026
…, Table Carry Test (#2591)

## Summary

Promotes develop to main, carrying:

- #2588 Put the Managed Bin Directory on install-tools.sh's Own PATH
When the Caller Omits It
- #2589 Run bootstrap.sh's Whole Main Flow Against a Stub Download and
Stub Tools
- #2586 Pin the Table Carry Onto a Second-Format Lite Round That Finds
Nothing
- #2593 Assert the Lite Table-Carry Test's Own Premise

Fixes #2257
Fixes #1767
Fixes #2282

🤖 Generated with [Claude Code](https://claude.com/claude-code)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants