зеркало из https://github.com/microsoft/git.git
t5801: "VAR=VAL shell_func args" is forbidden
It is not a portable expectation that a single-shot environment variable assignment works when calling a shell function, not a command. Set and export the variable before calling "test_must_fail git push" instead. This change would not hurt because this is the last command in the subprocess and the environment will not seep through to later tests without using a single-shot assignment. Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
Родитель
664059fb62
Коммит
1afe6e4044
|
@ -118,7 +118,9 @@ test_expect_success 'pushing without refspecs' '
|
||||||
(cd local2 &&
|
(cd local2 &&
|
||||||
echo content >>file &&
|
echo content >>file &&
|
||||||
git commit -a -m ten &&
|
git commit -a -m ten &&
|
||||||
GIT_REMOTE_TESTGIT_REFSPEC="" test_must_fail git push 2>../error) &&
|
GIT_REMOTE_TESTGIT_REFSPEC="" &&
|
||||||
|
export GIT_REMOTE_TESTGIT_REFSPEC &&
|
||||||
|
test_must_fail git push 2>../error) &&
|
||||||
grep "remote-helper doesn.t support push; refspec needed" error
|
grep "remote-helper doesn.t support push; refspec needed" error
|
||||||
'
|
'
|
||||||
|
|
||||||
|
|
Загрузка…
Ссылка в новой задаче