Thread (33 messages) 33 messages, 3 authors, 2026-02-14

Re: [PATCH v2 1/2] repo: add a default output format to enum output_format

From: Patrick Steinhardt <hidden>
Date: 2026-01-08 06:13:30

On Wed, Jan 07, 2026 at 06:28:59PM -0300, Lucas Seiki Oshiro wrote:
quoted
This is missing a test.
Indeed, I'll add a test for `--format=default`.
quoted
It would for example be nice to verify that
"--format=nul --format=default" does the expected thing.
Would it be necessary? We already have a test asserting that the
last "--format" wins:

test_expect_success 'git repo info uses the last requested format' '
	echo "layout.bare=false" >expected &&
	git repo info --format=nul -z --format=keyvalue layout.bare >actual &&
	test_cmp expected actual
'
Yup, but we don't have any test that verifies we do the right thing when
the user asks for the default format. So it's mostly an additional check
that the default format can be requested as expected, which would in the
normal case be a no-op as, well, it's the default. So if you specify a
different format before we verify that it can reset to the default.

Patrick
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help