зеркало из https://github.com/microsoft/git.git
t7102 (reset): don't hardcode SHA-1 in expected outputs
The expected SHA-1 digests are always available in variables. Use them instead of hardcoding. Signed-off-by: Alexey Shumkin <Alex.Crezoff@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
Родитель
77a6815d7d
Коммит
375775bb12
|
@ -192,7 +192,8 @@ test_expect_success \
|
|||
'changing files and redo the last commit should succeed' '
|
||||
echo "3rd line 2nd file" >>secondfile &&
|
||||
git commit -a -C ORIG_HEAD &&
|
||||
check_changes 3d3b7be011a58ca0c179ae45d94e6c83c0b0cd0d &&
|
||||
head4=$(git rev-parse --verify HEAD) &&
|
||||
check_changes $head4 &&
|
||||
test "$(git rev-parse ORIG_HEAD)" = \
|
||||
$head5
|
||||
'
|
||||
|
@ -211,7 +212,7 @@ test_expect_success \
|
|||
git reset --hard HEAD~2 &&
|
||||
check_changes ddaefe00f1da16864591c61fdc7adb5d7cd6b74e &&
|
||||
test "$(git rev-parse ORIG_HEAD)" = \
|
||||
3d3b7be011a58ca0c179ae45d94e6c83c0b0cd0d
|
||||
$head4
|
||||
'
|
||||
|
||||
>.diff_expect
|
||||
|
@ -326,10 +327,11 @@ test_expect_success '--hard reset to HEAD should clear a failed merge' '
|
|||
git checkout branch2 &&
|
||||
echo "3rd line in branch2" >>secondfile &&
|
||||
git commit -a -m "change in branch2" &&
|
||||
head3=$(git rev-parse --verify HEAD) &&
|
||||
|
||||
test_must_fail git pull . branch1 &&
|
||||
git reset --hard &&
|
||||
check_changes 77abb337073fb4369a7ad69ff6f5ec0e4d6b54bb
|
||||
check_changes $head3
|
||||
'
|
||||
|
||||
>.diff_expect
|
||||
|
|
Загрузка…
Ссылка в новой задаче