Re: [PATCH v3 02/10] t5526: stop asserting on stderr literally
- From
- Jonathan Tan <jonathantanmy@google.com>
- Date
- Feb 24, 2022, 23:05 UTC
- Message-ID
- <20220224230523.2877129-1-jonathantanmy@google.com>
- In-Reply-To
- <20220224100842.95827-3-chooglen@google.com>
Glen Choo <chooglen@google.com> writes:
Show 33 quoted lines
> diff --git a/t/t5526-fetch-submodules.sh b/t/t5526-fetch-submodules.sh
> index 0e93df1665..a3890e2f6c 100755
> --- a/t/t5526-fetch-submodules.sh
> +++ b/t/t5526-fetch-submodules.sh
> @@ -13,6 +13,32 @@ export GIT_TEST_FATAL_REGISTER_SUBMODULE_ODB
>
> pwd=$(pwd)
>
> +check_sub() {
> + NEW_HEAD=$1 &&
> + cat <<-EOF >$pwd/expect.err.sub
> + Fetching submodule submodule
> + From $pwd/submodule
> + OLD_HEAD..$NEW_HEAD sub -> origin/sub
> + EOF
> +}
> +
> +check_deep() {
> + NEW_HEAD=$1 &&
> + cat <<-EOF >$pwd/expect.err.deep
> + Fetching submodule submodule/subdir/deepsubmodule
> + From $pwd/deepsubmodule
> + OLD_HEAD..$NEW_HEAD deep -> origin/deep
> + EOF
> +}
> +
> +check_super() {
> + NEW_HEAD=$1 &&
> + cat <<-EOF >$pwd/expect.err.super
> + From $pwd/.
> + OLD_HEAD..$NEW_HEAD super -> origin/super
> + EOF
> +}These don't do any checking, but just write what's expected to a file. Could these be called something like write_sub_expected etc.?
Other than that, the patches up to this look fine (besides the comments left by others).