Hi Paul,
Paul Campbell wrote:
> --- a/contrib/subtree/t/t7900-subtree.sh
> +++ b/contrib/subtree/t/t7900-subtree.sh
> @@ -465,4 +465,34 @@ test_expect_success 'verify one file change per commit' '
[...]
> +test_expect_success 'change in subtree is pushed okay' '
> + cd copy0 && create new_file && git commit -m"Added new_file" &&
> + cd .. && git subtree push --prefix=copy0 2>&1 | \
If it possible to restrict the chdirs to subshells, that can make the
test more resiliant to early failures without breaking later tests.
That is:
(
cd copy0 &&
create new_file &&
test_tick &&
git commit -m "add new_file"
) &&
git subtree push --prefix=copy0 >output 2>&1 &&
grep "..." output
> + grep
> "^\s\{3\}[0-9a-f]\{7\}\.\.[0-9a-f]\{7\}\s\s[0-9a-f]\{40\}\s->\ssub1$"
This might not be portable if I understand
Documentation/CodingGuidelines correctly.
[...]
> + (grep "^copy3 . sub2$" .gitsubtree && die || true) &&
! grep "^copy3 . sub2\$" .gitsubtree &&
Hope that helps,
Jonathan
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html