test(lanes): add e2e tests for bit reset after lane merge main#10266
Merged
Conversation
Cover three scenarios: 1. Diverged with auto-snap - reset removes merge snap, reverts lane head 2. Fast-forward (main ahead) - reset reverts lane head to pre-merge 3. --no-auto-snap - reset throws "nothing to reset"
Contributor
There was a problem hiding this comment.
Pull request overview
Adds a new Harmony e2e test suite documenting how bit reset behaves after bit lane merge main, focusing on how lane heads/snaps are affected vs. workspace files.
Changes:
- Introduces e2e coverage for
bit resetafter mergingmaininto a lane in three scenarios (diverged auto-snap, “fast-forward”, and--no-auto-snap). - Asserts lane-head behavior and verifies that merged file content remains on disk and appears as “modified” after reset.
- Fix --no-snap → --no-auto-snap in case 3 JSDoc comment - Clarify case 2 description: unmodified snap still creates diverge
Covers the case where --no-snap prevents both snap creation AND lane head updates. bit reset has nothing to reset in this scenario.
GiladShoham
approved these changes
Apr 1, 2026
Replace 5 redundant cases with 3 distinct scenarios: 1. Diverged (auto-snap) - reset removes merge snap, reverts head 2. True fast-forward (component born on lane) - reset reverts head 3. --no-snap - nothing to reset
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add e2e tests documenting the behavior of
bit resetafterbit lane merge mainfor three scenarios:bit resetis consistent: it only removes local snaps/tags and reverts lane heads — never touches files. For full merge undo (including files), usebit lane merge-abort.