]> git.ipfire.org Git - thirdparty/git.git/commitdiff
t7201: put each command on a separate line
authorCharvi Mendiratta <charvi077@gmail.com>
Tue, 20 Oct 2020 12:11:52 +0000 (17:41 +0530)
committerJunio C Hamano <gitster@pobox.com>
Thu, 22 Oct 2020 17:37:57 +0000 (10:37 -0700)
Modern practice is to avoid multiple commands per line,
and instead place each command on its own line.

Signed-off-by: Charvi Mendiratta <charvi077@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
t/t7201-co.sh

index 5898182fd22a651d803f53498c53f204266d61b7..b36a93056fd8ea5b0fc489d92c3bacf3633c3498 100755 (executable)
@@ -157,7 +157,8 @@ test_expect_success 'checkout -m with merge conflict' '
 '
 
 test_expect_success 'format of merge conflict from checkout -m' '
-       git checkout -f master && git clean -f &&
+       git checkout -f master &&
+       git clean -f &&
 
        fill b d >two &&
        git checkout -m simple &&
@@ -180,7 +181,9 @@ test_expect_success 'format of merge conflict from checkout -m' '
 '
 
 test_expect_success 'checkout --merge --conflict=diff3 <branch>' '
-       git checkout -f master && git reset --hard && git clean -f &&
+       git checkout -f master &&
+       git reset --hard &&
+       git clean -f &&
 
        fill b d >two &&
        git checkout --merge --conflict=diff3 simple &&
@@ -205,7 +208,9 @@ test_expect_success 'checkout --merge --conflict=diff3 <branch>' '
 '
 
 test_expect_success 'switch to another branch while carrying a deletion' '
-       git checkout -f master && git reset --hard && git clean -f &&
+       git checkout -f master &&
+       git reset --hard &&
+       git clean -f &&
        git rm two &&
 
        test_must_fail git checkout simple 2>errs &&
@@ -218,7 +223,8 @@ test_expect_success 'switch to another branch while carrying a deletion' '
 test_expect_success 'checkout to detach HEAD (with advice declined)' '
        git config advice.detachedHead false &&
        rev=$(git rev-parse --short renamer^) &&
-       git checkout -f renamer && git clean -f &&
+       git checkout -f renamer &&
+       git clean -f &&
        git checkout renamer^ 2>messages &&
        test_i18ngrep "HEAD is now at $rev" messages &&
        test_line_count = 1 messages &&
@@ -237,7 +243,8 @@ test_expect_success 'checkout to detach HEAD (with advice declined)' '
 test_expect_success 'checkout to detach HEAD' '
        git config advice.detachedHead true &&
        rev=$(git rev-parse --short renamer^) &&
-       git checkout -f renamer && git clean -f &&
+       git checkout -f renamer &&
+       git clean -f &&
        GIT_TEST_GETTEXT_POISON=false git checkout renamer^ 2>messages &&
        grep "HEAD is now at $rev" messages &&
        test_line_count -gt 1 messages &&
@@ -254,7 +261,8 @@ test_expect_success 'checkout to detach HEAD' '
 '
 
 test_expect_success 'checkout to detach HEAD with branchname^' '
-       git checkout -f master && git clean -f &&
+       git checkout -f master &&
+       git clean -f &&
        git checkout renamer^ &&
        H=$(git rev-parse --verify HEAD) &&
        M=$(git show-ref -s --verify refs/heads/master) &&
@@ -269,7 +277,8 @@ test_expect_success 'checkout to detach HEAD with branchname^' '
 '
 
 test_expect_success 'checkout to detach HEAD with :/message' '
-       git checkout -f master && git clean -f &&
+       git checkout -f master &&
+       git clean -f &&
        git checkout ":/Initial" &&
        H=$(git rev-parse --verify HEAD) &&
        M=$(git show-ref -s --verify refs/heads/master) &&
@@ -284,7 +293,8 @@ test_expect_success 'checkout to detach HEAD with :/message' '
 '
 
 test_expect_success 'checkout to detach HEAD with HEAD^0' '
-       git checkout -f master && git clean -f &&
+       git checkout -f master &&
+       git clean -f &&
        git checkout HEAD^0 &&
        H=$(git rev-parse --verify HEAD) &&
        M=$(git show-ref -s --verify refs/heads/master) &&