[1/1] t1308-config-set: fix a test that has a typo
diff mbox series

Message ID 7b88e36723e3e6d51118d62211f487b497c532cc.1570710932.git.gitgitgadget@gmail.com
State New
Headers show
Series
  • t1308-config-set: fix a test that has a typo
Related show

Commit Message

erik chen via GitGitGadget Oct. 10, 2019, 12:35 p.m. UTC
From: Tanay Abhra <tanayabh@gmail.com>

Change test 'find value_list for a key from a configset' to redirect the
result to 'expect' instead of 'except' which was a typo.

With this change, the test case actually fails because it uses
`configset_get_value`. Clearly, this was intended to be
`configset_get_value_multi` since the test expects a list of values
instead of a single value, so let's fix that, too.

Originally contributed as https://github.com/git/git/pull/451.

Signed-off-by: Tanay Abhra <tanayabh@gmail.com>
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
---
 t/t1308-config-set.sh | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

Comments

Johannes Schindelin Oct. 10, 2019, 8:48 p.m. UTC | #1
Team,

On Thu, 10 Oct 2019, Tanay Abhra via GitGitGadget wrote:

> diff --git a/t/t1308-config-set.sh b/t/t1308-config-set.sh
> index d0a2727b85..7b4e1a63eb 100755
> --- a/t/t1308-config-set.sh
> +++ b/t/t1308-config-set.sh
> @@ -166,14 +166,14 @@ test_expect_success 'find value with highest priority from a configset' '
>  '
>
>  test_expect_success 'find value_list for a key from a configset' '
> -	cat >except <<-\EOF &&
> +	cat >expect <<-\EOF &&

I should note that I looked through all of the hits of `git grep -w
except -- t/` and did not find any other typo.

Thanks,
Johannes

> +	lama
> +	ball
>  	sam
>  	bat
>  	hask
> -	lama
> -	ball
>  	EOF
> -	test-tool config configset_get_value case.baz config2 .git/config >actual &&
> +	test-tool config configset_get_value_multi case.baz config2 .git/config >actual &&
>  	test_cmp expect actual
>  '
>
> --
> gitgitgadget
>
Junio C Hamano Oct. 11, 2019, 5:35 a.m. UTC | #2
Johannes Schindelin <Johannes.Schindelin@gmx.de> writes:

> I should note that I looked through all of the hits of `git grep -w
> except -- t/` and did not find any other typo.

Thanks.

Patch
diff mbox series

diff --git a/t/t1308-config-set.sh b/t/t1308-config-set.sh
index d0a2727b85..7b4e1a63eb 100755
--- a/t/t1308-config-set.sh
+++ b/t/t1308-config-set.sh
@@ -166,14 +166,14 @@  test_expect_success 'find value with highest priority from a configset' '
 '
 
 test_expect_success 'find value_list for a key from a configset' '
-	cat >except <<-\EOF &&
+	cat >expect <<-\EOF &&
+	lama
+	ball
 	sam
 	bat
 	hask
-	lama
-	ball
 	EOF
-	test-tool config configset_get_value case.baz config2 .git/config >actual &&
+	test-tool config configset_get_value_multi case.baz config2 .git/config >actual &&
 	test_cmp expect actual
 '