2 test_description
='Test stg commit'
5 test_expect_success
'Initialize the StGIT repository' '
9 # stg commit with top != head should not succeed, since the committed
10 # patches are poptentially lost.
11 test_expect_success
'Commit when top != head (should fail)' '
13 git reset --hard HEAD^ &&
14 h=$(git rev-parse HEAD)
15 command_error stg commit &&
16 test $(git rev-parse HEAD) = $h &&
17 test "$(echo $(stg series))" = "> foo"