t3000-t3999: fix broken &&-chains
[gitweb.git] / t / t3700-add.sh
index 0aae21d6984bf0bd5c7c7de425a021da6122beee..618750167aed8d99a57b2642713d12406cd2e5f6 100755 (executable)
@@ -156,9 +156,9 @@ test_expect_success 'git add with filemode=0, symlinks=0, and unmerged entries'
 test_expect_success 'git add with filemode=0, symlinks=0 prefers stage 2 over stage 1' '
        git rm --cached -f file symlink &&
        (
-               echo "100644 $(git hash-object -w stage1) 1     file"
-               echo "100755 $(git hash-object -w stage2) 2     file"
-               echo "100644 $(printf 1 | git hash-object -w -t blob --stdin) 1 symlink"
+               echo "100644 $(git hash-object -w stage1) 1     file" &&
+               echo "100755 $(git hash-object -w stage2) 2     file" &&
+               echo "100644 $(printf 1 | git hash-object -w -t blob --stdin) 1 symlink" &&
                echo "120000 $(printf 2 | git hash-object -w -t blob --stdin) 2 symlink"
        ) | git update-index --index-info &&
        git config core.filemode 0 &&
@@ -187,7 +187,7 @@ test_expect_success 'git add --refresh with pathspec' '
        echo >foo && echo >bar && echo >baz &&
        git add foo bar baz && H=$(git rev-parse :foo) && git rm -f foo &&
        echo "100644 $H 3       foo" | git update-index --index-info &&
-       test-chmtime -60 bar baz &&
+       test-tool chmtime -60 bar baz &&
        >expect &&
        git add --refresh bar >actual &&
        test_cmp expect actual &&
@@ -265,7 +265,7 @@ test_expect_success 'git add to resolve conflicts on otherwise ignored path' '
        git reset --hard &&
        H=$(git rev-parse :1/2/a) &&
        (
-               echo "100644 $H 1       track-this"
+               echo "100644 $H 1       track-this" &&
                echo "100644 $H 3       track-this"
        ) | git update-index --index-info &&
        echo track-this >>.gitignore &&
@@ -331,9 +331,8 @@ test_expect_success 'git add --dry-run --ignore-missing of non-existing file out
        test_i18ncmp expect.err actual.err
 '
 
-test_expect_success 'git add empty string should invoke warning' '
-       git add "" 2>output &&
-       test_i18ngrep "warning: empty strings" output
+test_expect_success 'git add empty string should fail' '
+       test_must_fail git add ""
 '
 
 test_expect_success 'git add --chmod=[+-]x stages correctly' '