This repository is designed to test all features of the Git Scope Pro IntelliJ Plugin.
- 3 branches:
main,feature/models-enhancement,feature/utils-expansion - 10 tags: v0.1.0, v0.2.0-alpha, v0.3.0, v0.4.0-beta, v0.5.0, v1.0.0, cleanup, logging-update, refactor-services, submodule-init
- 13 Java files across 3 packages (packageA, packageB, packageC)
- 12 commits with various types of changes (additions, modifications, deletions)
- 2 branches:
master,feature/enhanced-parsing - 3 tags: lib-v1.0.0, lib-v1.1.0, lib-v1.2.0
- 4 Java utility files
- 3 commits on master, 2 additional commits on feature branch
-
Clone the repository with submodules:
git clone --recurse-submodules https://github.com/hoxi/git-scope-pro-tests.git
-
If already cloned without submodules, initialize them:
git submodule update --init --recursive
-
Open the project in IntelliJ IDEA with the Git Scope Pro plugin installed
The tests are organized into logical groups for easier execution and understanding:
- Section A: Basic Scope Creation & Reference Types (Tests 1-6)
- Section B: Scope UI & Navigation Features (Tests 7-12)
- Section C: Branch & Tag Operations (Tests 13-15)
- Section D: Submodule Testing (Tests 17-18)
- Section E: Bug Fixes Verification (Tests 19-21)
- Section F: Advanced Features (Tests 22-25)
- Test 1: Create scope with v0.5.0, verify Change Browser shows correct files, open diff for ConfigService.java
- Test 2: Create scope with v0.2.0-alpha and v0.4.0-beta, compare differences in Change Browser
- Test 3: Single-click files in Change Browser to open preview tabs, double-click for permanent tabs
- Test 4: Create scope using commit hash (e.g., 6ee9035), verify changes shown
- Test 5: Rename scope tab, hover to see original hash/name, restore original name
- Test 6: Create scopes with HEAD
5 and HEAD10, compare differences - Test 7: Verify status bar shows current scope name, updates on scope switch
- Test 8: Use Alt+H to toggle between HEAD and last scope
- Test 9: Select file in Change Browser, press Ctrl+D to open diff
- Test 10: Open diff, use F7/Shift+F7 to navigate between changes within the diff
- Test 11: Create scope with v0.3.0, open Main.java, verify gutter highlights lines added after v0.3.0
- Test 12: Right-click file in Change Browser, test Show Diff, Show in Project, and Rollback (using IntelliJ built-in)
- Test 13: Create scope with v0.4.0, switch between branches, verify scope auto-updates (gutter and Change Browser)
- Test 14: Create scope with origin/feature/models-enhancement
- Test 15: Create local branch, verify it appears as LOCAL in scope selector, delete branch, verify it disappears
- Test 17: Create scope with v0.3.0, verify submodule libs/common-lib shown as modified
- Test 18: Create scope in submodule with lib-v1.0.0, switch to feature/enhanced-parsing branch, compare
- Test 19: Open Main.java, create scopes with v0.3.0 and v0.5.0, switch between them, verify diff updates
- Test 20: Use Alt+F1 to open Select In dialog, verify Git Scope appears; test crosshair button
- Test 21: Create scope, modify file, open Commit diff, switch scopes, verify diff continues working
- Test 22: Create 3 scopes, use right-click to reorder tabs, restart IntelliJ, verify order persists
- Test 23: Use Alt+F1, verify Git Scope in Select In dialog
- Test 24: Right-click commit in Git Log, create scope from commit
- Test 25: Create two scopes: main (full) and main..HEAD (common ancestor), compare differences in MathUtils.java
Objective: Verify basic scope creation with tags and diff viewing
- Open the Git Scope tool window (View → Tool Windows → Git Scope)
- Create a new scope and select v0.5.0 tag
- Expected: Change Browser should show all files changed between v0.5.0 and current HEAD
- Verify you see changes in:
ConfigService.java(refactored with singleton pattern)DataService.java(added capacity and search methods)CacheService.java(newly added)Main.java(integrated all packages)
- Right-click on
ConfigService.java→ Show Diff - Expected: Diff window opens showing the refactoring changes (singleton pattern added)
Objective: Test comparing between two specific tags
- Create a scope selecting v0.2.0-alpha tag
- Expected: Shows all changes from v0.2.0-alpha to HEAD
- Switch scope to v0.4.0-beta
- Expected: Change Browser updates to show changes from v0.4.0-beta to HEAD
- Verify differences between the two views:
- v0.2.0-alpha scope should show more files (packageB, packageC, submodule changes)
- v0.4.0-beta scope should show fewer files (only changes after that tag)
Objective: Test preview tab behavior with single click in Change Browser
- Create a scope selecting v0.5.0 tag
- Single-click on a file in Change Browser (e.g.,
ConfigService.java) - Expected: File opens in a preview tab (italicized tab name)
- Single-click on another file (e.g.,
DataService.java) - Expected: Preview tab is replaced with the new file
- Double-click on a file
- Expected: File opens in a permanent tab (non-italicized)
Objective: Test using specific commit hashes
- Get a commit hash from the middle of history:
git log --oneline
- Copy the hash for "Add logging statements to Main.java using LoggingService" (e.g.,
6ee9035) - Create a scope with this commit hash
- Expected: Shows all changes since that commit
- Open
Main.javain Change Browser - Expected: Should show logging additions and all subsequent changes
Objective: Test renaming scope tabs and restoring original names
- Create a scope with a commit hash (e.g.,
6ee9035) - Right-click on the scope tab and select Rename
- Enter a custom name like "Logging Changes"
- Expected: Tab displays "Logging Changes"
- Hover over the renamed tab
- Expected: Tooltip shows the original commit hash (e.g.,
6ee9035) - Right-click on the renamed tab and restore the original name
- Expected: Tab displays the original commit hash again
Objective: Test relative git references
- Create a scope with HEAD~5
- Expected: Shows changes from 5 commits ago to current HEAD
- Create a scope with HEAD~10
- Expected: Shows changes from 10 commits ago to current HEAD
- Compare the two - HEAD~10 should show more changes
Objective: Verify status bar shows current scope
- Create a scope named "My Test Scope" selecting v1.0.0
- Expected: Status bar at bottom should display "My Test Scope" or similar indicator
- Switch to different scope
- Expected: Status bar updates to show new scope name
- Clear/deactivate scope
- Expected: Status bar shows default state (e.g., "HEAD")
Objective: Test quick toggle between HEAD and last scope
- Create a scope selecting v0.5.0
- Press Alt+H
- Expected: Should toggle to HEAD (no scope filter)
- Press Alt+H again
- Expected: Should toggle back to v0.5.0 scope
- Verify Change Browser updates accordingly each time
Objective: Test quick diff opening
- Create a scope selecting v0.4.0-beta
- Select a changed file in Change Browser (e.g.,
ConfigService.java) - Press Ctrl+D
- Expected: Diff window opens for selected file showing changes
Objective: Test stepping forward and backward between changes within a diff
- Create a scope selecting v0.5.0 tag
- Open
Main.javain Change Browser and show diff - Press F7 in the diff window
- Expected: Navigate to next change/hunk in the diff
- Press Shift+F7
- Expected: Navigate to previous change/hunk in the diff
Objective: Verify gutter highlights modified lines relative to selected scope
- Return to main branch
- Enable gutter highlighting: Settings → Version Control → Enable "Highlight modified lines in gutter"
- Create a scope selecting v0.3.0 tag
- Open
Main.javain the editor - Expected: Lines added after v0.3.0 should be highlighted in the gutter:
- Import statements for StringUtils, ConfigService, DataService, User, Product
- All demo code (user creation, product creation, string utilities demo, data service demo)
- Switch scope to v0.5.0
- Expected: Fewer lines highlighted (only changes after v0.5.0)
Objective: Test right-click context menu actions
- Create a scope selecting v0.5.0
- Right-click on a changed file in Change Browser
- Select Show Diff
- Expected: Diff window opens showing changes
- Right-click on a file in Change Browser
- Select Show in Project
- Expected: Project panel expands and highlights the selected file
- Create a scope selecting v0.2.0-alpha
- Right-click on
StringUtils.javain Change Browser - Select Rollback to scope version (using IntelliJ's built-in rollback)
- Expected: IntelliJ prompts to confirm rollback to previous HEAD version
- Confirm the rollback
- Expected: File content reverts to v0.2.0-alpha version (only has isEmpty, capitalize, reverse methods)
- Verify in editor that methods added later (truncate, countOccurrences, repeat) are removed
- Undo the rollback using IntelliJ's Local History or VCS → Revert
Objective: Test that scope automatically updates when switching branches
- Switch to branch feature/models-enhancement:
git checkout feature/models-enhancement
- Create a scope selecting v0.4.0 tag
- Expected: Shows changes specific to feature/models-enhancement branch
- Note the files and gutter highlighting in the editor
- Switch to branch main:
git checkout main
- Expected: Scope automatically updates - Change Browser shows different files, gutter highlighting updates
- Switch to branch feature/utils-expansion:
git checkout feature/utils-expansion
- Expected: Scope automatically updates again - Change Browser and gutter reflect the new branch
- Verify that both Change Browser and gutter highlighting update automatically with each branch switch
Objective: Test comparing with remote branches
- Return to main branch and ensure remote branches are fetched:
git checkout main git fetch origin
- Create a scope selecting origin/feature/models-enhancement
- Expected: Shows appropriate branch differences
Objective: Verify local branches appear/disappear correctly in scope selector
- Ensure you're on main branch
- Open Git Scope tool window and click to create a new scope
- In the branch/tag selector, verify you see existing branches marked as:
- LOCAL:
main,feature/models-enhancement,feature/utils-expansion - REMOTE:
origin/main,origin/feature/models-enhancement,origin/feature/utils-expansion
- LOCAL:
- Create a new local branch from current position:
git checkout -b test/local-branch-verification
- Open the scope selector again (or create a new scope)
- Expected:
test/local-branch-verificationappears in the list marked as LOCAL - Select this local branch as the scope base
- Expected: Scope is created successfully
- Make a small change to verify scope is working:
echo "// Test comment" >> src/main/java/net/tagpad/Main.java
- Expected: Change Browser shows
Main.javaas modified relative to the branch point - Switch back to main branch:
git checkout main
- Delete the local test branch:
git branch -d test/local-branch-verification
- Open scope selector again
- Expected:
test/local-branch-verificationno longer appears in the LOCAL branches list - If you had a scope using that branch, verify it either:
- Shows an error/warning that the branch no longer exists, OR
- Becomes inactive/invalid
Success:
- Local branches are clearly marked as LOCAL
- New local branches immediately appear in scope selector
- Deleted local branches immediately disappear from scope selector
- Plugin handles branch deletion gracefully
Objective: Verify plugin detects and shows submodule changes
- Create a scope selecting v0.3.0 tag
- Expected: Change Browser should show
libs/common-libas modified - Select the submodule in Change Browser
- Expected: Should indicate submodule has been updated to a different commit
- Create a scope selecting submodule-init tag
- Expected: Should show the initial submodule addition
Objective: Test viewing changes within the submodule itself and branch comparison
- Create a scope in the submodule context selecting lib-v1.0.0 tag
- Expected: Shows all changes in submodule files since lib-v1.0.0:
Parser.java(added)Constants.java(updated version and values)DateUtils.java(added)
- Switch to feature branch:
cd libs/common-lib git checkout feature/enhanced-parsing - Create a scope selecting lib-v1.1.0
- Expected: Shows changes on the feature branch:
- Enhanced
Parser.javawith overloaded methods - New
JsonUtils.java
- Enhanced
- Return to master branch and compare:
git checkout master
- Expected: Different files shown (DateUtils instead of JsonUtils)
Objective: Verify switching between different scopes for a specific file shows correct diffs
Bug: IDE native line indentation guides were disabled when Git Scope plugin was enabled
- Return to main repository root (if in submodule)
- Open
Main.javain the editor - Create a scope selecting v0.3.0 tag
- Expected: Gutter shows lines added after v0.3.0
- Right-click on
Main.javain Change Browser and select Show Diff - Expected: Diff shows changes from v0.3.0 to HEAD
- Create another scope selecting v0.5.0 tag
- Right-click on
Main.javain Change Browser and select Show Diff - Expected: Diff shows changes from v0.5.0 to HEAD (fewer changes than v0.3.0)
- Switch between the two scopes
- Expected: Diff and gutter highlighting update automatically to reflect the selected scope
Success: Diff correctly shows changes for the selected scope, and switching scopes updates the diff accordingly
Objective: Verify "Select In" integration and crosshair navigation
Feature: Added "Git Scope" to "Select In" action and crosshair button
- Open a changed file in the editor (e.g.,
ConfigService.java) - Right-click in the editor or use shortcut Alt+F1
- Select "Select In" from context menu
- Expected: "Git Scope" appears as an option in the Select In dialog
- Choose "Git Scope"
- Expected: Git Scope tool window opens and highlights the current file in the Change Browser
- Look for a crosshair/target icon button in Git Scope tool window toolbar
- Open a different file in editor (e.g.,
DataService.java) - Click the crosshair button in Git Scope window
- Expected: Git Scope navigates to and highlights the currently open file
Success: Select In integration works and crosshair button locates current file
Objective: Verify Commit: diff window works correctly with local modifications and scope changes
Bug: Commit panel diff failed when file was open in another tab and non-HEAD scope was selected
- Create a scope selecting v0.5.0 (not HEAD)
- Open
DataService.javain editor - Make a local modification (e.g., add a comment):
// This is a test comment - Expected: Gutter shows the local change relative to v0.5.0 scope
- Open Git tool window (View → Tool Windows → Git)
- In the Commit tab, find
DataService.javain the changed files list - Double-click to open Commit: diff window
- Expected: Commit diff opens showing your local modification
- Verify the diff is showing the difference correctly
- With Commit: diff window still open, switch to a different scope (e.g., v0.4.0-beta)
- Expected: Commit diff continues to work correctly, showing local changes against HEAD (not the scope)
- Switch scope back to v0.5.0
- Expected: Commit diff still works correctly
- Toggle scope with Alt+H (to HEAD)
- Expected: Commit diff remains functional
- Keep Commit: diff window open
- Close the original
DataService.javaeditor tab (not the Commit: diff) - Switch focus to Commit: diff window
- Expected: Commit diff still displays and works correctly
- Switch scopes again while only Commit: diff is open
- Expected: Diff continues to function
- Close the Commit: diff window
- Re-open
DataService.javafrom Project view - Expected: File opens with gutter highlighting relative to currently selected scope
- Verify local modifications are still shown in gutter
- Switch scopes
- Expected: Gutter updates to show changes relative to new scope
- Modify another file (e.g.,
ConfigService.java) - Open Commit: diff for
ConfigService.java - Keep first Commit: diff window also open (so you have 2 Commit: diffs)
- Switch scopes multiple times
- Expected: Both Commit: diff windows continue working correctly
Success: Commit: diff window always works regardless of:
- Which scope is selected
- Whether original file tab is open
- Switching scopes while diff is open
- Multiple Commit: diff windows open simultaneously
Objective: Verify scope tabs can be reordered and persist across restarts
Feature: Right-click on scope tabs to move them left or right, order persists
Note: Drag-and-drop for tab reordering is not supported
- Create multiple scopes (at least 3):
- Scope 1: v0.3.0 (name it "Version 0.3")
- Scope 2: v0.5.0 (name it "Version 0.5")
- Scope 3: v1.0.0 (name it "Version 1.0")
- Verify initial tab order (left to right)
- Right-click on "Version 1.0" tab (rightmost)
- Expected: Context menu shows options including "Move Left" or "Move Right"
- Select "Move Left"
- Expected: "Version 1.0" tab moves one position to the left
- Right-click on "Version 0.3" tab (leftmost)
- Expected: Context menu shows appropriate move options
- Select "Move Right"
- Expected: "Version 0.3" tab moves one position to the right
- Arrange tabs in a specific order (e.g., 1.0, 0.3, 0.5)
- Note the exact order
- Close IntelliJ completely
- Reopen IntelliJ and the project
- Open Git Scope tool window
- Expected: Scope tabs appear in the same order as before restart
- Create a new scope and reorder it
- Restart IntelliJ again
- Expected: New order is persisted
Success: Tab order can be customized using right-click context menu and persists through IDE restarts
Objective: Test project panel filter and "Select In" dialog integration
- Create any scope with changes
- Use Alt+F1 to open "Select In" dialog
- Verify "Git Scope" appears as an option
- Test navigation from Project panel to Git Scope
Objective: Test ability to use commits as scopes directly from Git panel
- Open Git tool window (View → Tool Windows → Git)
- Navigate to Log tab
- Right-click on a specific commit in the history
- Expected: Context menu includes option to create scope from this commit
- Create scope from commit
- Expected: New scope tab is created using that commit as the base
- Verify the scope works correctly
Objective: Test "Only Changes Since Common Ancestor" mode to show differences between branches
- Ensure you're on main branch
- Create a scope named "main full" selecting main branch (without common ancestor mode)
- Expected: Shows all changes from main to HEAD
- Create another scope named "main..HEAD" selecting main with Only Changes Since Common Ancestor enabled
- Expected: Shows only changes unique to current branch since diverging from main
- Compare the two scopes:
- "main full" should show more changes
- "main..HEAD" should show only changes since the common ancestor
- Open
MathUtils.javain the editor - Switch between the two scopes
- Expected:
MathUtils.javashows different gutter highlighting:- "main full" highlights all lines different from main branch tip
- "main..HEAD" highlights only lines changed since common ancestor
- Verify the diffs shown in Change Browser differ between the two scopes
Success: Common ancestor mode correctly identifies and shows only changes since the point where branches diverged
- Initial commit
- Add packageA with utility classes (StringUtils and MathUtils) - v0.2.0-alpha
- Add packageB with service classes - v0.3.0
- Add logging statements to Main.java - logging-update
- Add git submodule - submodule-init
- Add ArrayUtils and FileUtils - v0.4.0-beta
- Remove excessive debug logging - cleanup
- Update submodule to Parser version
- Add packageC with model classes - v0.5.0
- Refactor packageB - refactor-services
- Integrate all packages in Main.java - v1.0.0
- Update submodule to feature/enhanced-parsing branch
- feature/models-enhancement: 3 commits diverging from v0.5.0
- feature/utils-expansion: 3 commits diverging from v0.4.0-beta
- master: lib-v1.0.0 → lib-v1.1.0 → lib-v1.2.0
- feature/enhanced-parsing: diverges from lib-v1.1.0 with 2 additional commits
git submodule update --init --recursive- Ensure you're on the correct branch
- Refresh the Git Scope tool window
- Rebuild the project if needed
- Enable in Settings → Version Control → "Highlight modified lines in gutter"
- Ensure a scope is active
After completing all test cases, you should have verified:
- ✅ Scope creation with branches, tags, and commit hashes
- ✅ Change Browser shows correct diffs
- ✅ Preview tabs work with single-click, permanent tabs with double-click
- ✅ Line gutter highlighting works
- ✅ Keyboard shortcuts function correctly (Alt+H, Ctrl+D, F7/Shift+F7)
- ✅ Status bar widget shows current scope
- ✅ Right-click actions (Show Diff, Show in Project, Rollback) work
- ✅ Plugin handles various tag formats (semantic versions, alpha/beta, descriptive names)
- ✅ Navigation between changes in diffs works
- ✅ Git references (HEAD~N) work correctly
- ✅ Scope renaming works with tooltip showing original name and ability to restore
- ✅ Scope automatically updates when switching branches
- ✅ Remote branch comparisons work
- ✅ Local branches are clearly marked as LOCAL
- ✅ New local branches immediately appear in scope selector
- ✅ Deleted local branches immediately disappear from scope selector
- ✅ Plugin handles branch deletion gracefully
- ✅ Submodule changes are detected and displayed
- ✅ Plugin works in submodule contexts
- ✅ Submodule branch comparisons work
- ✅ Scope diff for specific files shows correct changes when switching scopes
- ✅ "Select In" action includes Git Scope option (Issue #59)
- ✅ Crosshair button locates current file in Git Scope window (Issue #59)
- ✅ Commit: diff window works with local modifications (Issue #56)
- ✅ Commit: diff persists through scope changes (Issue #56)
- ✅ Commit: diff works when original file tab is closed (Issue #56)
- ✅ Gutter highlighting restores correctly after closing Commit: diff (Issue #56)
- ✅ Scope tabs can be reordered via right-click context menu (drag-and-drop not supported)
- ✅ Scope tab order persists across IntelliJ restarts
- ✅ "Select In" dialog integration works
- ✅ Git panel integration allows creating scopes from commits
- ✅ Common ancestor mode correctly shows differences since branch divergence
If you find any issues with this test repository or want to add more test scenarios, please open an issue or pull request.
This is a test repository for the Git Scope Pro plugin. Use freely for testing purposes.