Files
lazygitclj/test/e2e/staging.tape
2026-01-21 17:49:39 -05:00

46 lines
896 B
VHS

# VHS E2E test for lazygitclj - File staging/unstaging
# Tests staging and unstaging files (like lazygit's space key)
Output test/e2e/output/staging.gif
Output test/e2e/output/staging.ascii
Require bb
Set Shell "bash"
Set FontSize 14
Set Width 1000
Set Height 600
Set Framerate 10
# Setup test repo and run lazygitclj
Type "./test/e2e/setup-test-repo.sh /tmp/lazygitclj-e2e-stage && cd /tmp/lazygitclj-e2e-stage && bb --config /home/ajet/repos/lazygitclj/bb.edn start"
Enter
Sleep 2s
# Should be on Files panel with some staged and unstaged files
# Move to the staged file and unstage it with space
Type " "
Sleep 500ms
# Move down to an unstaged file
Type "j"
Sleep 500ms
# Stage it with space
Type " "
Sleep 500ms
# Stage all with 'a' (like lazygit)
Type "a"
Sleep 500ms
# Move to a file and discard changes with 'd'
Type "j"
Sleep 500ms
Type "d"
Sleep 500ms
# Quit
Type "q"
Sleep 1s