7 test_expect_success setup
'
8 echo "#!/bin/sh" > not_ssh &&
9 echo "echo \"\$*\" > not_ssh_output" >> not_ssh &&
10 echo "exit 1" >> not_ssh &&
14 test_expect_success
'clone calls git upload-pack unqualified with no -u option' '
18 test_must_fail git clone localhost:/path/to/repo junk
20 echo "localhost git-upload-pack '\''/path/to/repo'\''" >expected &&
21 test_cmp expected not_ssh_output
24 test_expect_success
'clone calls specified git upload-pack with -u option' '
28 test_must_fail git clone -u ./something/bin/git-upload-pack localhost:/path/to/repo junk
30 echo "localhost ./something/bin/git-upload-pack '\''/path/to/repo'\''" >expected &&
31 test_cmp expected not_ssh_output