t5050: test bug fixed by recent logic correction
[topgit/pro.git] / t / t5050-update-orphans.sh
blob1bb05c7e97852fbc9c4b77b57e3731d24d7d440d
1 #!/bin/sh
3 test_description='unrelated orphan branches update okay'
5 . ./test-lib.sh
7 test_plan 4
9 test_expect_success 'setup' '
10 git config rerere.enabled 1 &&
11 git checkout --orphan t/branch &&
12 tg create --no-deps --topmsg branch HEAD &&
13 git checkout --orphan master &&
14 git read-tree --empty &&
15 git clean -f -q &&
16 echo new one > new &&
17 git add new &&
18 git commit -m new1 &&
19 git checkout --orphan master2 &&
20 git read-tree --empty &&
21 git clean -f -q &&
22 echo new two > new &&
23 git add new &&
24 git commit -m new2
27 test_expect_success LASTOK 'add dependencies' '
28 tg checkout -f t/branch &&
29 git clean -f -q &&
30 tg depend add --no-update master master2
33 test_expect_success LASTOK 'create resolution' '
34 test_must_fail tg update t/branch &&
35 echo new one > new &&
36 echo new two >> new &&
37 git add new &&
38 git commit -m resolved &&
39 tg update --abort
42 test_expect_success LASTOK 'update' '
43 tg update t/branch
46 test_done