mirror of
https://github.com/facebook/sapling.git
synced 2024-10-07 07:17:55 +03:00
tests: add a test showing crash rebasing a git commit
Differential Revision: D35201372 fbshipit-source-id: 7c44a39c249a2ee9e0a1a50afbb936010a146e38
This commit is contained in:
parent
5b816fdf81
commit
11b1132b26
40
eden/scm/tests/test-git-rebase-conflicts.t
Normal file
40
eden/scm/tests/test-git-rebase-conflicts.t
Normal file
@ -0,0 +1,40 @@
|
||||
#chg-compatible
|
||||
#require git no-windows
|
||||
|
||||
Test that rebasing in a git repo with conflicts work.
|
||||
|
||||
$ . $TESTDIR/git.sh
|
||||
$ setconfig diff.git=true ui.allowemptycommit=true
|
||||
$ enable rebase
|
||||
$ shorttraceback
|
||||
|
||||
Prepare the repo
|
||||
|
||||
$ hg init --git repo1
|
||||
$ cd repo1
|
||||
$ drawdag << 'EOS'
|
||||
> # B/A=0
|
||||
> A7 B # A5/A=3
|
||||
> : / # A3/A=2
|
||||
> A1 # A1/A=1
|
||||
> EOS
|
||||
|
||||
Rebase:
|
||||
|
||||
$ hg rebase -r $B -d $A7
|
||||
rebasing 5c2dbc94ad6b "B"
|
||||
merging A
|
||||
warning: 1 conflicts while merging A! (edit, then use 'hg resolve --mark')
|
||||
unresolved conflicts (see hg resolve, then hg rebase --continue)
|
||||
[1]
|
||||
|
||||
$ hg rebase --abort
|
||||
rebase aborted
|
||||
|
||||
Rebase with merge.printcandidatecommits:
|
||||
|
||||
$ hg rebase -r $B -d $A7 --config merge.printcandidatecommmits=1
|
||||
rebasing 5c2dbc94ad6b "B"
|
||||
merging A
|
||||
AttributeError: 'gitfilelog' object has no attribute 'linkrev'
|
||||
[255]
|
Loading…
Reference in New Issue
Block a user