1
0
mirror of https://github.com/jesseduffield/lazygit.git synced 2025-12-01 22:52:01 +02:00

add tests for dealing with remotes

This commit is contained in:
Jesse Duffield
2021-10-22 20:18:40 +11:00
parent 6388af70ac
commit 2008c39516
663 changed files with 1663 additions and 72 deletions

View File

@@ -0,0 +1,16 @@
myfile4 conflict
# Please enter the commit message for your changes. Lines starting
# with '#' will be ignored, and an empty message aborts the commit.
#
# interactive rebase in progress; onto ea4a99e
# Last command done (1 command done):
# pick efbb36c myfile4 conflict
# Next commands to do (3 remaining commands):
# pick 9147ce4 5
# pick e2251a5 6
# You are currently rebasing branch 'master' on 'ea4a99e'.
#
# Changes to be committed:
# modified: myfile4
#

View File

@@ -0,0 +1 @@
ea4a99ea801f54f1ec09a88a28c65eb4db5865aa branch 'master' of ../actual_remote

View File

@@ -0,0 +1 @@
ref: refs/heads/master

View File

@@ -0,0 +1 @@
efbb36c97316886b089b1b27233cd8bfdc37ed4a

View File

@@ -0,0 +1,18 @@
[core]
repositoryformatversion = 0
filemode = true
bare = false
logallrefupdates = true
ignorecase = true
precomposeunicode = true
[user]
email = CI@example.com
name = CI
[remote "origin"]
url = ../actual_remote
fetch = +refs/heads/*:refs/remotes/origin/*
[branch "master"]
remote = origin
merge = refs/heads/master
[pull]
rebase = interactive

View File

@@ -0,0 +1 @@
Unnamed repository; edit this file 'description' to name the repository.

View File

@@ -0,0 +1,7 @@
# git ls-files --others --exclude-from=.git/info/exclude
# Lines that start with '#' are comments.
# For a project mostly in C, the following would be a good set of
# exclude patterns (uncomment them if you want to use them):
# *.[oa]
# *~
.DS_Store

View File

@@ -0,0 +1,15 @@
0000000000000000000000000000000000000000 74ca3dec707dde7c92727d9490517e498360fea8 CI <CI@example.com> 1634896929 +1100 commit (initial): myfile1
74ca3dec707dde7c92727d9490517e498360fea8 ca58e8d47d619ffb625dc021f0ab2bb0f0bcf623 CI <CI@example.com> 1634896929 +1100 commit: myfile2
ca58e8d47d619ffb625dc021f0ab2bb0f0bcf623 3fb33027aedae13ab0796292c821a0258f6c2f7b CI <CI@example.com> 1634896929 +1100 commit: myfile3
3fb33027aedae13ab0796292c821a0258f6c2f7b ea4a99ea801f54f1ec09a88a28c65eb4db5865aa CI <CI@example.com> 1634896929 +1100 commit: myfile4
ea4a99ea801f54f1ec09a88a28c65eb4db5865aa ca58e8d47d619ffb625dc021f0ab2bb0f0bcf623 CI <CI@example.com> 1634896929 +1100 reset: moving to head^^
ca58e8d47d619ffb625dc021f0ab2bb0f0bcf623 efbb36c97316886b089b1b27233cd8bfdc37ed4a CI <CI@example.com> 1634896929 +1100 commit: myfile4 conflict
efbb36c97316886b089b1b27233cd8bfdc37ed4a 9147ce4817b84339d884cee1683f361fd3aa4696 CI <CI@example.com> 1634896929 +1100 commit: 5
9147ce4817b84339d884cee1683f361fd3aa4696 e2251a5b6d32bf5fc57f234946e3fabeba3b5cca CI <CI@example.com> 1634896929 +1100 commit: 6
e2251a5b6d32bf5fc57f234946e3fabeba3b5cca 89ee54b2ed7aff7c3aae24f64be85568f9a9d329 CI <CI@example.com> 1634896929 +1100 commit: 7
89ee54b2ed7aff7c3aae24f64be85568f9a9d329 ea4a99ea801f54f1ec09a88a28c65eb4db5865aa CI <CI@example.com> 1634896931 +1100 rebase -i (start): checkout ea4a99ea801f54f1ec09a88a28c65eb4db5865aa
ea4a99ea801f54f1ec09a88a28c65eb4db5865aa 29daf999882c9e60c6b6a2868913a6cfd856d620 CI <CI@example.com> 1634896933 +1100 rebase -i (continue): myfile4 conflict
29daf999882c9e60c6b6a2868913a6cfd856d620 5c32741b468f0ab8ddd243e9871dcc8dec5c35f9 CI <CI@example.com> 1634896933 +1100 rebase -i (pick): 5
5c32741b468f0ab8ddd243e9871dcc8dec5c35f9 423f7757eb2eea3de217b54447a94820af933d3a CI <CI@example.com> 1634896933 +1100 rebase -i (pick): 6
423f7757eb2eea3de217b54447a94820af933d3a bf4fb489636d4bde42e478b04cbdcc079dcd0183 CI <CI@example.com> 1634896933 +1100 rebase -i (pick): 7
bf4fb489636d4bde42e478b04cbdcc079dcd0183 bf4fb489636d4bde42e478b04cbdcc079dcd0183 CI <CI@example.com> 1634896933 +1100 rebase -i (finish): returning to refs/heads/master

View File

@@ -0,0 +1,10 @@
0000000000000000000000000000000000000000 74ca3dec707dde7c92727d9490517e498360fea8 CI <CI@example.com> 1634896929 +1100 commit (initial): myfile1
74ca3dec707dde7c92727d9490517e498360fea8 ca58e8d47d619ffb625dc021f0ab2bb0f0bcf623 CI <CI@example.com> 1634896929 +1100 commit: myfile2
ca58e8d47d619ffb625dc021f0ab2bb0f0bcf623 3fb33027aedae13ab0796292c821a0258f6c2f7b CI <CI@example.com> 1634896929 +1100 commit: myfile3
3fb33027aedae13ab0796292c821a0258f6c2f7b ea4a99ea801f54f1ec09a88a28c65eb4db5865aa CI <CI@example.com> 1634896929 +1100 commit: myfile4
ea4a99ea801f54f1ec09a88a28c65eb4db5865aa ca58e8d47d619ffb625dc021f0ab2bb0f0bcf623 CI <CI@example.com> 1634896929 +1100 reset: moving to head^^
ca58e8d47d619ffb625dc021f0ab2bb0f0bcf623 efbb36c97316886b089b1b27233cd8bfdc37ed4a CI <CI@example.com> 1634896929 +1100 commit: myfile4 conflict
efbb36c97316886b089b1b27233cd8bfdc37ed4a 9147ce4817b84339d884cee1683f361fd3aa4696 CI <CI@example.com> 1634896929 +1100 commit: 5
9147ce4817b84339d884cee1683f361fd3aa4696 e2251a5b6d32bf5fc57f234946e3fabeba3b5cca CI <CI@example.com> 1634896929 +1100 commit: 6
e2251a5b6d32bf5fc57f234946e3fabeba3b5cca 89ee54b2ed7aff7c3aae24f64be85568f9a9d329 CI <CI@example.com> 1634896929 +1100 commit: 7
89ee54b2ed7aff7c3aae24f64be85568f9a9d329 bf4fb489636d4bde42e478b04cbdcc079dcd0183 CI <CI@example.com> 1634896933 +1100 rebase -i (finish): refs/heads/master onto ea4a99ea801f54f1ec09a88a28c65eb4db5865aa

View File

@@ -0,0 +1 @@
0000000000000000000000000000000000000000 ea4a99ea801f54f1ec09a88a28c65eb4db5865aa CI <CI@example.com> 1634896929 +1100 fetch origin: storing head

View File

@@ -0,0 +1,5 @@
x}�A
1 �a�=E��4M�I@D���6)
��
�.\�}|�������}W�>x ����2�J��A*8!:��l�����X�On!Qu�F"�*�R
��!be�����v^�y^���m{ꩬ�b!a N��aܘ�����9⏛d�-�7�

View File

@@ -0,0 +1,2 @@
x��A
�0@Q�9��ɤ�4��c�L��!R"����~����H|��*x�\��2&��H1r��H

View File

@@ -0,0 +1,2 @@
x��A
�0@Q�9E��df�I"BW=�4N���R"����~�◵��[���wU��!z%�)U�0�$X#��P$d0������D�0�>D�dr13f, A�T�`���w��F{ƻ~�m�^��n�|ʜ1�3�s���T�?�i�:/���g8�

View File

@@ -0,0 +1,2 @@
x��A
�0@Q�9E��̤ɘ���U�1�N�ИR"����>��K�u���p껪e�I��P�� g�2��x���z2���V8D�̈́��L.� pv9C�,��`�ݟm��do����mՋ�z�H����K��`=������-˪�J{�u�n~/�>@

View File

@@ -0,0 +1 @@
bf4fb489636d4bde42e478b04cbdcc079dcd0183

View File

@@ -0,0 +1 @@
ea4a99ea801f54f1ec09a88a28c65eb4db5865aa

View File

@@ -0,0 +1 @@
test1

View File

@@ -0,0 +1 @@
test2

View File

@@ -0,0 +1 @@
test3

View File

@@ -0,0 +1 @@
conflict

View File

@@ -0,0 +1 @@
test

View File

@@ -0,0 +1 @@
test

View File

@@ -0,0 +1 @@
test

View File

@@ -0,0 +1 @@
ref: refs/heads/master

View File

@@ -0,0 +1,8 @@
[core]
repositoryformatversion = 0
filemode = true
bare = true
ignorecase = true
precomposeunicode = true
[remote "origin"]
url = /Users/jesseduffieldduffield/go/src/github.com/jesseduffield/lazygit/test/integration/pullRebaseInteractive/./actual

View File

@@ -0,0 +1 @@
Unnamed repository; edit this file 'description' to name the repository.

View File

@@ -0,0 +1,7 @@
# git ls-files --others --exclude-from=.git/info/exclude
# Lines that start with '#' are comments.
# For a project mostly in C, the following would be a good set of
# exclude patterns (uncomment them if you want to use them):
# *.[oa]
# *~
.DS_Store

View File

@@ -0,0 +1,2 @@
x��A
�0@Q�9��ɤ�4��c�L��!R"����~����H|��*x�\��2&��H1r��H

View File

@@ -0,0 +1,2 @@
x��A
�0@Q�9E��df�I"BW=�4N���R"����~�◵��[���wU��!z%�)U�0�$X#��P$d0������D�0�>D�dr13f, A�T�`���w��F{ƻ~�m�^��n�|ʜ1�3�s���T�?�i�:/���g8�

View File

@@ -0,0 +1,2 @@
# pack-refs with: peeled fully-peeled sorted
ea4a99ea801f54f1ec09a88a28c65eb4db5865aa refs/heads/master

View File

@@ -0,0 +1 @@
{"KeyEvents":[{"Timestamp":1280,"Mod":0,"Key":256,"Ch":112},{"Timestamp":2032,"Mod":0,"Key":13,"Ch":13},{"Timestamp":2392,"Mod":0,"Key":13,"Ch":13},{"Timestamp":2640,"Mod":0,"Key":258,"Ch":0},{"Timestamp":2896,"Mod":0,"Key":256,"Ch":32},{"Timestamp":3384,"Mod":0,"Key":13,"Ch":13},{"Timestamp":4158,"Mod":0,"Key":256,"Ch":113}],"ResizeEvents":[{"Timestamp":0,"Width":272,"Height":74}]}

View File

@@ -0,0 +1,52 @@
#!/bin/sh
set -e
cd $1
git init
git config user.email "CI@example.com"
git config user.name "CI"
echo test1 > myfile1
git add .
git commit -am "myfile1"
echo test2 > myfile2
git add .
git commit -am "myfile2"
echo test3 > myfile3
git add .
git commit -am "myfile3"
echo test4 > myfile4
git add .
git commit -am "myfile4"
cd ..
git clone --bare ./actual actual_remote
cd actual
git reset --hard HEAD~2
echo conflict > myfile4
git add .
git commit -am "myfile4 conflict"
echo test > myfile5
git add .
git commit -am "5"
echo test > myfile6
git add .
git commit -am "6"
echo test > myfile7
git add .
git commit -am "7"
git remote add origin ../actual_remote
git fetch origin
git branch --set-upstream-to=origin/master master
git config pull.rebase interactive

View File

@@ -0,0 +1 @@
{ "description": "When user has configured pull with interactive rebase, ensure we handle conflicts", "speed": 5 }