2 test_description
='Test that "stg float" can handle conflicts'
5 test_expect_success
'Test setup' '
7 echo expected.txt >> .git/info/exclude &&
8 echo first line > foo.txt &&
11 echo foo >> foo.txt &&
14 echo foo2 >> foo.txt &&
20 cat > expected.txt
<<EOF
29 test_expect_success
'Float a patch, causing a conflict with the next patch' '
30 conflict stg float p1 &&
31 test "$(echo $(stg series))" = "+ p0 > p2 - p1" &&
32 test "$(stg id p2)" = "$(git rev-list HEAD~0 -n 1)" &&
33 test "$(stg id p0)" = "$(git rev-list HEAD~1 -n 1)" &&
34 test "$(stg status)" = "UU foo.txt" &&
35 test_cmp foo.txt expected.txt