Skip to content

Commit d1b13df

Browse files
ao2gitster
authored andcommitted
t7411: merge tests 5 and 6
Tests 5 and 6 check for the effects of the same commit, merge the two tests to make it more straightforward to clean things up after the test has finished. The cleanup will be added in a future commit. Signed-off-by: Antonio Ospite <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 45f5ef3 commit d1b13df

File tree

1 file changed

+5
-13
lines changed

1 file changed

+5
-13
lines changed

t/t7411-submodule-config.sh

Lines changed: 5 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -82,29 +82,21 @@ Submodule name: 'a' for path 'b'
8282
Submodule name: 'submodule' for path 'submodule'
8383
EOF
8484

85-
test_expect_success 'error in one submodule config lets continue' '
85+
test_expect_success 'error in history of one submodule config lets continue, stderr message contains blob ref' '
8686
(cd super &&
8787
cp .gitmodules .gitmodules.bak &&
8888
echo " value = \"" >>.gitmodules &&
8989
git add .gitmodules &&
9090
mv .gitmodules.bak .gitmodules &&
9191
git commit -m "add error" &&
92-
test-tool submodule-config \
93-
HEAD b \
94-
HEAD submodule \
95-
>actual &&
96-
test_cmp expect_error actual
97-
)
98-
'
99-
100-
test_expect_success 'error message contains blob reference' '
101-
(cd super &&
10292
sha1=$(git rev-parse HEAD) &&
10393
test-tool submodule-config \
10494
HEAD b \
10595
HEAD submodule \
106-
2>actual_err &&
107-
test_i18ngrep "submodule-blob $sha1:.gitmodules" actual_err >/dev/null
96+
>actual \
97+
2>actual_stderr &&
98+
test_cmp expect_error actual &&
99+
test_i18ngrep "submodule-blob $sha1:.gitmodules" actual_stderr >/dev/null
108100
)
109101
'
110102

0 commit comments

Comments
 (0)